Senior Member
Join Date: Nov 2013
Location: Andover, Ma
Posts: 632
|
I have a template that I am working on that adds a slam to the character with damage based on the size of the base creature.
I've tried most of the night to get the script to apply, and while it does seem to be applying it internally it doesn't display the proper damage on the weapons tab. I've tried every timing ranging from First/500 all the way to Final/50000 Code:
if (hero.tagis[Size.Diminutive] <> 0) then perform hero.child[wSlam].assign[wMain.1_1] endif if (hero.tagis[Size.Diminutive] <> 0) then perform hero.child[wSlam].assign[wMain.1d2_2] endif if (hero.tagis[Size.Tiny] <> 0) then perform hero.child[wSlam].assign[wMain.1d3_3] endif if (hero.tagis[Size.Small] <> 0) then perform hero.child[wSlam].assign[wMain.1d4_4] endif if (hero.tagis[Size.Medium] <> 0) then perform hero.child[wSlam].assign[wMain.1d6_5] endif if (hero.tagis[Size.Large] <> 0) then perform hero.child[wSlam].delete[wMain.?] perform hero.child[wSlam].assign[wMain.1d8_6] endif if (hero.tagis[Size.Huge] <> 0) then perform hero.child[wSlam].assign[wMain.2d6_104] endif if (hero.tagis[Size.Gargantuan] <> 0) then perform hero.child[wSlam].assign[wMain.2d8_204] endif if (hero.tagis[Size.Colossal] <> 0) then perform hero.child[wSlam].assign[wMain.4d6_106] endif |
#1 |
Senior Member
Volunteer Data File Contributor
Join Date: Jan 2010
Location: Chicago, IL (USA)
Posts: 10,729
|
You need to add logic to remove the current weapon damage first.
Like this: Code:
perform hero.child[wSlam].delete[wMain.?] Hero Lab Resources: Pathfinder - d20pfsrd and Pathfinder Pack Setup 3.5 D&D (d20) - Community Server Setup 5E D&D - Community Server Setup Hero Lab Help - Hero Lab FAQ, Editor Tutorials and Videos, Editor & Scripting Resources. Created by the community for the community - Realm Works kickstarter backer (Alpha Wolf) and Beta tester.- d20 HL package volunteer editor. |
#2 |
Senior Member
Join Date: Nov 2013
Location: Andover, Ma
Posts: 632
|
Quote:
But thank you, very much it works. |
|
#3 |
Spy
Join Date: Jan 2011
Location: Van Nuys, California
Posts: 1,220
|
Another options is to increment the natural weapon's wDamage field. The following code implements a 1 step increase in damage (say size M to size L). Just an FYI.
Code:
hero.child[wSlam].field[wDamage].value += 1 |
#4 |
|
|