• 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

Help With Script

Manalishi66

Well-known member
rying to create my own kensai class. Need script help to do the following.....

The Kensai selects one type of weapon or unarmed strikes as his chosen weapon. When striking with his chosen weapon, he gains a bonus to damage equal to half his level (round up).

A Kensai of at least 5th level gains a +1 on attack rolls with his chosen weapon. This bonus increases by +1 every four levels to a maximum of +4 at 17th level.

Failed to find scripts that helped me. Can someone please show me a working script that I could add to this Class Special Ability to make it work.

script so far (just damage bonus right now), but I cant get the damage bonus add to the weapon chosen?


~ If we're not shown, just get out now
doneif (tagis[Helper.ShowSpec] = 0)

~ If we're disabled, just get out now
doneif (tagis[Helper.SpcDisable] <> 0)

~ If we're not the first copy, just get out now
doneif (tagis[Helper.FirstCopy] = 0)

var bonus as number
bonus = (#levelcount[KEN])/ 2
field[abValue].value += round(bonus,0,1)

field[abSumm].text = "+" & field[abValue].value & " damage with your chosen weapon."
field[livename].text = field[thingname].text & " +" & field[abValue].value

doneif (hero.childfound[cFtrWeapCh].field[usrChosen1].ischosen = 0)

field[livename].text &= ": " & hero.childfound[cFtrWeapCh].field[usrChosen1].chosen.field[name].text
var searchexpr as string
searchexpr = hero.childfound[cFtrWeapCh].field[usrChosen1].chosen.tagids[IsWeapon.?,"|"]

foreach pick in hero from BaseWep where searchexpr
eachpick.field[wDamBonus].value += bonus
 
Back
Top