Junior Member
Join Date: Jul 2008
Posts: 8
|
Hey everyone!
I finally got a copy of Hero Lab, and I'm very excited to be using it! I only have a slight coding background, however, so I'm not at all certain how to start properly adding in various new materials that I want to incorporate. The tutorial is great for the basic stuff, but things like "boostraps" and "pick-reqs" are still pretty unintelligible to me. The first thing I'm trying to add is the Practiced Spellcaster feat, from Complete Arcane/Divine. I used Spell Focus as a starting point, thinking it'd help since, like Practiced Spellcaster, it improves one's caster level. So far, I was able to successfully add in the prerequisite (Spellcraft 4 ranks), but because I used Spell Focus as a starting point, it still has 1 eval script and 1 eval rule remaining. I'm not sure what to do about those (and only have some idea about what they are). Basically, I want to incorporate the effects of Practiced Spellcaster, and remove any lingering effects from Spell Focus, but I'm not sure what (if any) coding to do, or where. Any help anyone can provide would be appreciated. Thanks! |
#1 |
Senior Member
Lone Wolf Staff
Join Date: May 2005
Posts: 13,207
|
Remember to describe what you're trying to accomplish in your message - my copy of complete arcane is rather buried, so I don't know what you're trying to do.
The eval rule in spell focus works to make sure that you've selected a school and that if you have the spell focus feat multiple times, to give an error if you select the same school twice. The eval script's main function is to add a tag to the hero so that it's easier to test for the presence of spell focus in a specific school. If your feat doesn't add any game effects that can be tracked within HL, you can probably go ahead and delete the eval rule and eval script, and just leave your feat as text-only. |
#2 |
Senior Member
Join Date: Jan 2007
Location: NW Arkansas
Posts: 1,321
|
Since Practiced Spellcaster adds from 0-4 caster levels depending on how many non-spellcaster levels you have, I'm sure it'd need an eval script to determine that number for the character. How would you do something like that?
Working on - |
#3 |
Junior Member
Join Date: Jul 2008
Posts: 8
|
Quote:
Practiced Spellcaster increases your caster level by as much as 4 in a spellcasting class, but only if you have at least 4 Hit Die/levels that are non-spellcasting. A good example is a Fighter 5/Wizard 4 who takes the feat. Since he has 5 Fighter levels, which aren't spellcasting, he'd gain no new spells per day, etc. but his caster level for the spells he did cast would be as though he were an 8th-level Wizard. That said, if he'd only been a Fighter 3/Wizard 4, he'd only have gained +3 from the feat, since he only had 3 non-spellcaster Hit Dice. The feat can be selected multiple times if you have multiple spellcasting classes (e.g. a Cleric 4/Wizard 4). I'm fairly certain caster level is something that HL tracks, so I wanted to ask here about that. On a broader note, is there any sort of tutorial available for the finer aspects of coding in HL? I'd prefer to learn how to do this sort of thing myself rather than publicly ask for help with each change I want to make. |
|
#4 |
Senior Member
Lone Wolf Staff
Join Date: May 2005
Posts: 13,207
|
Didn't want to start simply, did you.
First, to see caster level (since it's currently not displayed), go to the development menu, check "Enable Data File Debugging", then go to the bottom of that menu, "Floating info Windows", "Show Selection Fields", and choose the helper object for the class you're interested in. For example: Cleric (cHelpClr) or Wizard (cHelpWiz) I've only gotten some of the feat. I'm stumped on the rest. On your feat, set "Restrict To..." to "Picks on Hero" Set "Select From..." to "Classes" click on the "Eval Scripts" button, set the phase to "Pre-Levels (Users)", and put the following in the script itself: Code:
~ If we're disabled, do nothing if (tagis[Helper.FtDisable] <> 0) then done endif ~ If we haven't chosen anything, get out now if (field[fChosen].ischosen = 0) then done endif field[fChosen].chosen.field[cMagicLev].value +=4 The problem with what I've written is in order to set the caster level equal to the minimum of (caster level +4, character level) , you need to know what the caster level is before your minimum() function. But, if you want any additions to the caster level to be calculated, you need to add them before the caster level is set. I'm afraid Colen will have to help you with making a feat that doesn't add 4 to caster level no matter what. I did think of a sort-of work-around. On the feat, check the "Show in Charges List?" checkbox and set "Total Charges" to 4. Replace the last line of the script with: Code:
field[fChosen].chosen.field[cMagicLev].value +=field[hUsed].value |
#5 |
Senior Member
Lone Wolf Staff
Join Date: May 2005
Posts: 13,207
|
In terms of tutorials, the way I learned was to look for other things in the game that are handled similarly. For example, to learn about the selector, look at feats like weapon focus, skill focus, and spell focus - none of them use the class selector I'm using in this feat, but you can use them to learn about selectors in general.
To learn about how to use bootstraps, in the editor, open a file, go to the source folder within the default directory, and open srd_monstrous.dat - that contains all the non-standard races, and races and classes are the things that make the most use of bootstraps. Races are easier to decipher than classes, so page through all the monstrous races, and see what sorts of things they're bootstrapping. Don't worry about pick-reqs yet - that's a very advanced topic. Also, read through this forum. A lot of solutions are already here, and even if its not exactly what you're looking for, it might point you in the right direction. |
#6 |
Junior Member
Join Date: Jul 2008
Posts: 8
|
Quote:
Quote:
I just want to make sure that setting it to "Classes" won't make for a restriction later on. Quote:
Quote:
Quote:
Thanks for your help! |
|||||
#7 |
Senior Member
Lone Wolf Staff
Join Date: May 2005
Posts: 13,207
|
Quote:
Quote:
Quote:
Quote:
|
|||||||
#8 |
Junior Member
Join Date: Jul 2008
Posts: 8
|
Quote:
That said, the rest of the scripts you wrote worked great so far! They tested fine, and integrated without any problems. Thanks for your help! Quote:
|
||
#9 |
Senior Member
Lone Wolf Staff
Join Date: May 2005
Posts: 13,207
|
Quote:
The development menu is one of those at the top of the program. |
||
#10 |
Thread Tools | |
Display Modes | |
|
|