• 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

Getting Damage String

Steev42

Well-known member
Is there a way to get the final damage string from a particular weapon, so as to include it as part of the livename of another special? I tried to take a look at Constrict, as it would usually have similar function, but it seems that there are multiple versions of that with the values entered by hand.
 
Ok, since there was no response, I'll try again.

Code:
var damage as string
damage = hero.childfound[wBite].field[wDamage].value

That code gives me a value of 7. I tried throwing .field[livename].text in place of the .value, and got an error about using a reserved word in a script.

Looking at the Pick Fields for the bite, the wDamage field has a value of 7 and a final of 2d6+6. Is it at all possible for me to pick up that Final value somehow?
 
No - the text version isn't generated until after all scripts are finished running, so you can't access it with another script.
 
No - the text version isn't generated until after all scripts are finished running, so you can't access it with another script.
Maybe I am missing something but I think he could do a script to calculate this value for himself but your right in saying its not done for him.

He will have all the information he would just have to put it together. In example the 2d6 weapon would have a tag of "wMain.2d6_7" and you can easily strip off the _7 part of the string. Then you can get the final value of +6 bonus to damage from the weapon. Sorry I forget the field name or names as you may have to do some addition. So all of this would want to be done VERY late in the timing to make sure all the other scripts have run.

Then it would be just a case of putting the two pieces together into "2d6+6" and putting that as the livename of the other Thing.
 
Back
Top