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
Matt Droz
Senior Member
 
Join Date: Apr 2010
Posts: 152

Old July 6th, 2012, 05:38 AM
I'm trying to add a magic item that grants the wearer the Two-Weapon Fighting feat. If he already has that, then they get the Improved Two-Weapon Fighting feat.

So, I'm able to assign TWF without any issue, but I'm running into issues assigning ImpTWF if they have TWF. Basically, I've got the code so that it checks if the TWF feat is already there, then assigns a Custom tag. Using the Custom tag as the requirement, it should work, but I run into a timing error [...occurs after earliest rule/script (First/2380)], which is when the actual feat is assigned (as opposed to the item's virtual feat).

Any suggestion? If I move the timing earlier than 2380 for the check, it doesn't see the feat, so it never assigns the Improved feat. But if it's later, the error comes up.

Matt Droz Community material (Forgotten Realms & Non-SRD/Retro)
Matt Droz is offline   #1 Reply With Quote
Sendric
Senior Member
 
Join Date: Jul 2010
Posts: 3,147

Old July 6th, 2012, 06:14 AM
Can you not just use the TWF feat itself as the requirement?
Sendric is offline   #2 Reply With Quote
Matt Droz
Senior Member
 
Join Date: Apr 2010
Posts: 152

Old July 6th, 2012, 06:36 AM
The feat isn't assigned until First/2400, so it can't detect it until then. But the bootstrap needs to run before First 2380.

Matt Droz Community material (Forgotten Realms & Non-SRD/Retro)
Matt Droz is offline   #3 Reply With Quote
Sendric
Senior Member
 
Join Date: Jul 2010
Posts: 3,147

Old July 6th, 2012, 07:05 AM
Yea, I see the problem. Unfortunately, I don't see an obvious solution. I'll give it some thought and let you know if I manage to come up with anything.

Edit: If you don't need the feats to show up in the feat section, and just need the functionality of the feats, here is a possible solution:

Code:
if (#hasfeat[fTwoWep] = 0) then
  perform hero.assign[Hero.TwoWep]
elseif (#hasfeat[fImpTwoWep] = 0) then
  perform hero.assign[Hero.TwoWepImp]
endif

Last edited by Sendric; July 6th, 2012 at 07:12 AM.
Sendric is offline   #4 Reply With Quote
Matt Droz
Senior Member
 
Join Date: Apr 2010
Posts: 152

Old July 9th, 2012, 09:27 AM
That did it!

Matt Droz Community material (Forgotten Realms & Non-SRD/Retro)
Matt Droz is offline   #5 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:14 PM.


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