• Please note: In an effort to ensure that all of our users feel welcome on our forums, we’ve updated our forum rules. You can review the updated rules here: http://forums.wolflair.com/showthread.php?t=5528.

    If a fellow Community member is not following the forum rules, please report the post by clicking the Report button (the red yield sign on the left) located on every post. This will notify the moderators directly. If you have any questions about these new rules, please contact support@wolflair.com.

    - The Lone Wolf Development Team

Scripting...oh my

Enforcer84

Well-known member
I'm trying to script two things, one I believe is easy but I can't find an example to crib off of and the other is less so...maybe.

easy one: I'd like to have an activated ability that grants a skill bonus. (Checking show on activated list gives me that, yay) but how do I tell my script if this box is checked add skill bonus? I think I saw it here at some point but I'm unable to find it...


harder one: ok so another race has the ability to grant fast healing 1 to their allies, this ability works a number of times per day = to their CHA bonus (minimum 1; and I'd like to add a feat to increase this...and think I can figure that out from the various feats that also allow that).

Additionally, it has a duration - a number of rounds equal to 3+ their Charisma bonus (again, minimum 1)

Finally, the ability improves as they level, at character level 8 it goes to Fast heal 2
at Character level 16 it goes to Fast heal 3

does that make any sense?
 
easy one: I'd like to have an activated ability that grants a skill bonus. (Checking show on activated list gives me that, yay) but how do I tell my script if this box is checked add skill bonus? I think I saw it here at some point but I'm unable to find it...
Its helpful to qualify what this script will run on as Ability is to generic (Racial Ability, Class Ability, Ability)?

For many you can use:
Code:
If (field[abilActive].value <> 0) Then
   #skillbonus[UNIQUE_ID_GOES_HERE] += 2
Endif
But without knowing the exact thing its hard to know for sure.

Also to find this yourself go to "Develop->Enable Data File Debugging". Then go to the In-Play tab and right click on the "?" of the Thing and pick "Show Debug Fields for xxxxx". In the new window is a list of all the fields. If you click the activated ability ON/OFF you will see one of the fields change from 0 to 1.


harder one: ok so another race has the ability to grant fast healing 1 to their allies, this ability works a number of times per day = to their CHA bonus (minimum 1; and I'd like to add a feat to increase this...and think I can figure that out from the various feats that also allow that).
The macro your looking for is #trkmax[]. That can be used to increase the maximum value of the of Tracker on the Thing:
Code:
#trkmax[UNIQUE_ID_GOES_HERE] += 2

Additionally, it has a duration - a number of rounds equal to 3+ their Charisma bonus (again, minimum 1)

Finally, the ability improves as they level, at character level 8 it goes to Fast heal 2
at Character level 16 it goes to Fast heal 3

does that make any sense?
I am not sure exactly what your asking here? Are you trying to script the racial ability to do this or have the feat above increase these values?

If the feat is to increase these duration is usually stored as "abDuration" so you can use macro #duration[ability_id]. The fasting healing could be stored in one of the abValue (1,2,3,4) so without knowing the exact Thing I can't be sure. But you can use what I showed you above to find out the values of those abValue fields on the Thing. Then you can use the macro #value[], #value2[], #value3[], or #value4[] to increase it.
 
Thanks for Answering Shadow!

it's a racial ability:
Adds +10 to Stealth when immobile in shadows/darkness.
I think that will be sufficient


the second one I'm scripting the ability. The Feat I think I can hammer out.

Goal is this:

This Race can cast Fast Healing 1 on self or ally 1+CHA Bonus times per day for a similar duration (1 + CHA Bonus/Rounds per use)
When the character achieves 8th level it bumps to fast heal 2
When they reach 16th it's fast heal 3
The other variables stay the same.

The feat idea popped into my head as I was writing and it fell onto the keyboard. Ignore that :)
 
Last edited:
New Scripting Desire!

I'm creating a Paladin like class for the not always good race of sanguine elves, so I'd like their abilities to differ slightly for their alignment (must be Lawful)

Lawful Neutral gets Smite Chaos
Lawful Evil can choose (once) Smite Good or Smite Chaos

Additionally I want them to have Auras of Law or Evil respectively.

But I'm assuming once I figure out how to make the alignment and choice abilities I can cobble this pretty easily.
Oh and thanks to the awesome posters/teachers here. I know I don't grasp this easily but your examples have been much appreciated.
 
Alignment assigns two tags to the hero. One for the lawful/chaotic axis and one for the good/evil. You can check for the appropriate tags using the tagis[TAG_NAME] function.
 
Back
Top