Lone Wolf Development Forums  

Go Back   Lone Wolf Development Forums > Hero Lab Forums > HL - Pathfinder Roleplaying Game

Notices

Reply
 
Thread Tools Display Modes
Bob G
Senior Member
 
Join Date: Nov 2017
Location: Trafford, PA, USA
Posts: 226

Old December 27th, 2017, 07:26 PM
Hi everyone,

I've got a few more questions about scripts that are confounding me. Any help would be very appreciated.

1. Trying to put a class ability that grants fast healing when current hit points are below 50% of total hit points. I'm having trouble locating the child that current hit points are stored. Can anyone help direct me?

2. Another problem is a custom expression I am trying to write that does a foreach on memorized spells. I found a tag group name 'Memorized', so I used the following script:
Code:
foreach pick in hero from BaseSpell where "Memorized.?"
     field[usrCandid1].text = splice(field[usrCandid1].text, eachpick.tagids[thingid.?], " | ")
     nexteach
But the results produced all spells in the hero's spellbook, not just the ones they had memorized. What's the correct tag to use in the custom expression?

3. Lastly (same ability as #2), once the user selects a memorized spell, I want to change the tag or field to reflect that it has been cast. I found the field 'sCastCount', but that produced an error message, so I tried decreasing the field 'sCastLeft', which didn't error, but did not produce the desired result. Guidance on this would be great.

Thanks as always, and happy holidays to all of you.
Bob G is offline   #1 Reply With Quote
Bob G
Senior Member
 
Join Date: Nov 2017
Location: Trafford, PA, USA
Posts: 226

Old December 28th, 2017, 05:25 AM
Update to question 1: I found the child by using the 'Show Task List (Active Hero)' floating info window in the Develop menu! Total and current hit points are stored in the child "Totals".

I hope this helps anyone with similar problems.
Bob G is offline   #2 Reply With Quote
Minous
Senior Member
 
Join Date: May 2015
Posts: 830

Old December 28th, 2017, 10:23 AM
The spells cast is tracked in the in play or spells tab.
Minous is offline   #3 Reply With Quote
Bob G
Senior Member
 
Join Date: Nov 2017
Location: Trafford, PA, USA
Posts: 226

Old December 29th, 2017, 04:14 AM
Quote:
Originally Posted by Minous View Post
The spells cast is tracked in the in play or spells tab.
Right, I found those, but none of the fields that I tried accomplish the goal. I tried 'sCastCount', but that produced an error message, so I tried decreasing the field 'sCastLeft', which didn't error, but did not produce the desired result. Not sure where to go from here.
Bob G is offline   #4 Reply With Quote
Minous
Senior Member
 
Join Date: May 2015
Posts: 830

Old December 29th, 2017, 06:48 AM
What are you trying to do with the loop/script?
Minous is offline   #5 Reply With Quote
Bob G
Senior Member
 
Join Date: Nov 2017
Location: Trafford, PA, USA
Posts: 226

Old December 29th, 2017, 12:48 PM
Quote:
Originally Posted by Minous View Post
What are you trying to do with the loop/script?
I am trying to write that does a foreach on memorized spells. I found a tag group name 'Memorized', so I used the following script:

Code:
foreach pick in hero from BaseSpell where "Memorized.?"
     field[usrCandid1].text = splice(field[usrCandid1].text, eachpick.tagids[thingid.?], " | ")
     nexteach
But the results produced all spells in the hero's spellbook, not just the ones they had memorized. What's the correct tag to use in the custom expression?

The goal is to create a usr field where the candidates are memorized spells.
Bob G is offline   #6 Reply With Quote
Aaron
Senior Member
 
Join Date: Oct 2011
Posts: 6,793

Old December 29th, 2017, 05:38 PM
Is this limited to just spellbook casters, or should it be catching, for example, spells memorized by a cleric? Should it not be iterating through spells known, like a sorcerer gets?
Aaron is offline   #7 Reply With Quote
Bob G
Senior Member
 
Join Date: Nov 2017
Location: Trafford, PA, USA
Posts: 226

Old December 29th, 2017, 07:13 PM
Quote:
Originally Posted by Aaron View Post
Is this limited to just spellbook casters, or should it be catching, for example, spells memorized by a cleric? Should it not be iterating through spells known, like a sorcerer gets?
Just spellbook casters, this is a class ability for a class that memorizes arcane spells.
Bob G is offline   #8 Reply With Quote
Aaron
Senior Member
 
Join Date: Oct 2011
Posts: 6,793

Old December 29th, 2017, 07:53 PM
SpellType.cHelpXXX (replace XXX with whatever is appropriate for your class) and CasterType.MemBook
Aaron is offline   #9 Reply With Quote
Bob G
Senior Member
 
Join Date: Nov 2017
Location: Trafford, PA, USA
Posts: 226

Old December 30th, 2017, 08:07 AM
Quote:
Originally Posted by Aaron View Post
SpellType.cHelpXXX (replace XXX with whatever is appropriate for your class) and CasterType.MemBook
Thanks Aaron. I got an invalid tag expression when I used this script:
Code:
foreach pick in hero from BaseSpell where "SpellType.cHelpArn" &  "CasterType.MemBook"
I get the feeling it's because the tag "SpellType.cHelpArn" isn't located in the BaseSpell component.
Bob G is offline   #10 Reply With Quote
Reply

Thread Tools
Display Modes

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 08:10 AM.


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