03-16-2019, 12:51 AM | #1 |
Join Date: Jun 2006
Location: Helmouth, The Netherlands
|
Leveled EQ modifiers with damage enhancement
Hi,
I'm trying to add similar Equipment modifiers together. Here's an example: I have the following three modifiers Code:
Lens:Adegan Single, +6000, Page(TF?), group(Components - Energy Blade), shortname(Lens:Single), gives(_ =+0.01 to owner::baseweight, =+$/textindexedvalue( $modetag(damtype), ("burn", 1d-1) ) to owner::damage$ listAs "+1d-1 to burning damage from Single Lens", =+1 to owner::armordivisor_ ) Code:
Lens:Adegan Double, +12000, Page(TF?), group(Components - Energy Blade), shortname(Lens:Double), gives(_ =+0.015 to owner::baseweight, =+$/textindexedvalue( $modetag(damtype), ("burn", 1d+1) ) to owner::damage$ listAs "+1d+1 to burning damage from Double Lens", =+2 to owner::armordivisor_ ) Code:
Lens:Adegan Triple, +18000, Page(TF?), group(Components - Energy Blade), shortname(Lens:Triple), gives(_ =+0.02 to owner::baseweight, =+$/textindexedvalue( $modetag(damtype), ("burn", 1d+3) ) to owner::damage$ listAs "+1d+3 to burning damage from Triple Lens", =+3 to owner::armordivisor_ ) Code:
Lens: Adegan, +6000/+12000/+18000, upto(3), Page(TF?), group(Components - Energy Blade), shortname(), levelnames(#List(LevelName Lenses)), gives(_ =+@indexedvalue(me::level,0.1,0.15,0.2) to owner::baseweight, =+@indexedvalue(me::level,1,2,3) to owner:armordivisor _ ) Code:
<LevelName Lenses> "Single","Double","Triple" I tried several ways with @IF, THEN and ELSE but then either the program hangs or its only increases the weight and armordivisor. Last edited by Lord Azagthoth; 03-17-2019 at 01:53 AM. |
03-17-2019, 09:25 AM | #2 |
GCA Prime
Join Date: Aug 2004
Location: Portland, OR
|
Re: Leveled EQ modifiers with damage enhancement
As is, the damage bonus will only apply to attack modes that already do damage of type "burn", and will apply to all of those. If the damtype is not already "burn" it will not apply the damage.
If the intent is to add the burning damage to any existing attack mode, the damage line needs to be a bit different. Could you please clarify your intent?
__________________
Armin D. Sykes | Visit my GCA5 blog for updates and previews. | Get GURPS Character Assistant 5 now at Warehouse 23. |
03-17-2019, 01:27 PM | #3 |
Join Date: Jun 2006
Location: Helmouth, The Netherlands
|
Re: Leveled EQ modifiers with damage enhancement
I just want to save space in the gdf files. And it has the benefit of less modifiers in the modifier tab.
The parts of the equipment often come in several "levels" with the same damtype but a better damage dice. In case of the lenses it doubles or triples the damage of a single lens. Other parts are leveled into standard, improved, expert, superior, and ultimate. Some of these have an increment in damage (e.g., none, +1d-2, +1d-1, +1d, +1d+1) but all with the same damagetype. I already contracted the separate modifiers into leveled modifiers which don't contain this programming line, saving lots of space. |
03-17-2019, 04:25 PM | #4 |
GCA Prime
Join Date: Aug 2004
Location: Portland, OR
|
Re: Leveled EQ modifiers with damage enhancement
(I'm short on sleep. Sorry if I misunderstand or miss the point.)
Um, okay. If all the damtypes are the same, why check them? This is the simplest addition to the gives to do the damage bit, but doesn't check for "burn" damage type: Code:
=+$indexedvalue(me::level,1d-1,1d+1,1d+3) to owner::damage$ Code:
=+$/if( @sametext( $modetag(damtype), "burn" ) then $indexedvalue( me::level,1d-1,1d+1,1d+3 ) ) to owner::damage$
__________________
Armin D. Sykes | Visit my GCA5 blog for updates and previews. | Get GURPS Character Assistant 5 now at Warehouse 23. |
03-18-2019, 04:00 PM | #5 |
Join Date: Jun 2006
Location: Helmouth, The Netherlands
|
Re: Leveled EQ modifiers with damage enhancement
Tnx,
The top one did the trick. I will try out the bottom line as soon as I get to parts that do other types of damage (rad & ion) |
Thread Tools | |
Display Modes | |
|
|