Lone Wolf Development Forums  

Go Back   Lone Wolf Development Forums > Hero Lab Forums > HL - Pathfinder Roleplaying Game
Register FAQ Community Today's Posts Search

Notices

Reply
 
Thread Tools Display Modes
Coopernicus
Member
 
Join Date: Aug 2010
Posts: 53

Old March 27th, 2011, 01:33 PM
What I actually want to do is create a feat so that a player can use any light or single handed slashing weapon to qualify for the Duelist's precise striking ability, not just the scimitar.

I'm thinking of including all single-handed axes, falcata, khopesh, kukri, longsword, sawtooth saber, shortsword, sickle, sword_aldori dueling, sword_bastard (only after the character can use 1-handed by taking exotic WP), temple sword, war razor and (even) whip.

I have named it Blade Dance but I'm new at this and have zero experience with coding.

So I used "copy new" using Dervish dance as a base and am wondering if any kind soul that knows how can reply with the proper code to replace

#hasfeat[fWepMart] + hero.tagis[WepProf.wScimitar] <> 0


with one for all single handed slashing weapons...

Or is it even possible?

Thanks
Coopernicus is offline   #1 Reply With Quote
Coopernicus
Member
 
Join Date: Aug 2010
Posts: 53

Old March 27th, 2011, 01:44 PM
SnapI just realized I also have to create a different weapon finesse feat and have blade dance accept that as a pre-req instead of regular weapon finesse...
Coopernicus is offline   #2 Reply With Quote
tatteredking
Senior Member
 
Join Date: Sep 2010
Location: Rochester, NY
Posts: 263

Old March 28th, 2011, 07:47 AM
I am just starting to code, but I needed something similar where I needed a certain number of Item Creation feats to qualify for a Feat. The Help link in the toolkit has some sample scripts. One of them, the one I am working with, went through the feats you had and counted feats of certain types. I think your application would be an extension of this as well, but I think you would have to have it check each individual slashing weapon you want in there to see if the Profile contains that feat.

May be an easier way. my script-fu is not strong
tatteredking is offline   #3 Reply With Quote
Mathias
Senior Member
Lone Wolf Staff
 
Join Date: May 2005
Posts: 13,217

Old March 28th, 2011, 08:34 AM
What I'd do here is to start with a copy of Dervish Dance - study its script - see how it's searching for all the scimitars.

Then, make your copy look for all light/single slashing weapons that aren't scimitars - that way, between the two feats, they'll cover the scimitars and the rest of the weapons you want to cover.

To figure out how the fact that a weapon is light or one handed is stored in Hero Lab, add many different weapons to a blank character - some light, some one-handed, some two-handed, and then in the Develop menu, make sure that the first option, "Enable Data File Debugging" is checked.

Now, right-click on those various weapons, and select "Show Selection Tags for XXXXX". Compare the lists between the various weapons, and see if you can pick out how light/one-handed/two-handed is stored - it's the wClass tags - wClass.Light and wClass.OneHanded.

Do the same for S vs. B vs. P - you'll find that those are the wType tags.

So, now we modify the foreach - change what it's looking for:

Code:
 
foreach pick in hero from BaseWep where "(wClass.Light | wClass.OneHanded) & wType.S & !IsWeapon.wScimitar"
So, that's looking for a weapon that is (either light or one-handed) and slashing, and not a scimitar (we're excluding scimitars here since this feat requires dervish dance, so the dervish dance feat will have already applied these changes to the scimitars).
Mathias is online now   #4 Reply With Quote
Coopernicus
Member
 
Join Date: Aug 2010
Posts: 53

Old March 28th, 2011, 09:11 AM
Wow, thanks Mathias.

I did start out with the Dervish Dance, but had unsuccessfully tried changing the code. I didn't actually have Dervish Dance as a pre-req, but now that you mention it, it's probably a fair idea.
Question is, how do I include it as a pre-req?

Here's my description of the feat itself;

Improved Dervish Dance
You have learned to use different blades with your Dervish Dance.

{b}Prerequisites{/b}: Dervish Dance, Dexterity 16, Weapon Focus, Perform (dance) 6 ranks, proficient with one-handed slashing melee weapon.

{b}Benefit{/b}: When wielding any one-handed slashing melee weapon with one hand, you can use your Dexterity modifier instead of your Strength modifier on melee attack and damage rolls. You treat the weapon as a one-handed piercing weapon for all feats and class abilities that require such a weapon (such as a duelist's precise strike ability). The weapon must be for a creature of your size. You cannot use this feat if you are carrying a weapon or shield in your off hand.


The code you wrote above, do I put that in Expr-reqs?

Thanks again
Coopernicus is offline   #5 Reply With Quote
Coopernicus
Member
 
Join Date: Aug 2010
Posts: 53

Old March 28th, 2011, 09:16 AM
Forget it, I see it goes in Eval scripts, and i think i got Dervish dance as the pre req all right... testing now...

ok I got an error;

Syntax error in 'eval' script for Thing 'fImDerDan' (Eval script '#2') on live 7
-> One or more 'if' statements is missing the closing 'endif' statements.

Here's my modified (from the original Dervish Dance) Eval script -


~ If we're disabled, do nothing
doneif (tagis[Helper.FtDisable] <> 0)

~ Assign the piercing weapon tag so any 1-handed slashing weapons work with Duelist abilities.
foreach pick in hero from BaseWep where "(wClass.Light | wClass.OneHanded) & wType.S & !IsWeapon.wScimitar"

Last edited by Coopernicus; March 28th, 2011 at 09:20 AM.
Coopernicus is offline   #6 Reply With Quote
Coopernicus
Member
 
Join Date: Aug 2010
Posts: 53

Old March 28th, 2011, 09:21 AM
line 7, not live 7...
Coopernicus is offline   #7 Reply With Quote
Mathias
Senior Member
Lone Wolf Staff
 
Join Date: May 2005
Posts: 13,217

Old March 28th, 2011, 09:23 AM
Go ahead and copy the entire script, please - that way, it's easier to count lines and see which one is line 7.
Mathias is online now   #8 Reply With Quote
Mathias
Senior Member
Lone Wolf Staff
 
Join Date: May 2005
Posts: 13,217

Old March 28th, 2011, 09:27 AM
Oh yeah - as a reminder, there are two Eval Scripts for dervish dance - you'll want to apply the same change to the foreach to both.
Mathias is online now   #9 Reply With Quote
Coopernicus
Member
 
Join Date: Aug 2010
Posts: 53

Old March 28th, 2011, 11:24 AM
Entire script, right - sorry...


~ If we're disabled, do nothing
doneif (tagis[Helper.FtDisable] <> 0)

~ Assign the piercing weapon tag so any 1-handed slashing weapons work with Duelist abilities.
foreach pick in hero from BaseWep where "(wClass.Light | wClass.OneHanded) & wType.S & !IsWeapon.wScimitar"


~ If we're disabled, do nothing
doneif (tagis[Helper.FtDisable] <> 0)

~ If we have a shield equipped or another weapon in our off hand, do nothing, we are done.
doneif (hero.tagis[Hero.EquipShld] + hero.tagis[Hero.EquipOff] <> 0)

~figure out the difference between our DEX and STR modifiers (minimum 0, since the feat says "can", not "must")
field[abValue].value += maximum(#attrmod[aDEX] - #attrmod[aSTR], 0)

~ Otherwise, go through to all scimitars on the hero and replace their Strength bonuses to Hit and Damage with Dex bonuses... Also apply the piercing weapon tag so we count for precise strike.
foreach pick in hero from BaseWep where "IsWeapon.wScimitar"
eachpick.field[wAttBonus].value += field[abValue].value
eachpick.field[wDamBonus].value += field[abValue].value
nexteach
Coopernicus is offline   #10 Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -8. The time now is 12:50 PM.


Powered by vBulletin® - Copyright ©2000 - 2024, vBulletin Solutions, Inc.
wolflair.com copyright ©1998-2016 Lone Wolf Development, Inc. View our Privacy Policy here.