Junior Member
Join Date: Oct 2018
Posts: 29
|
I was working on a conversion of the Dread Necromancer and ran into a problem. This guys has a class ability gained periodically (4th, 8th, 12th, etc..) that allows him to add spell to his "book." I developed this class using the Warmage (unrestricted) style of casting. And found the example of "Greater Spell Access" from the Magus to develop a script to add the spell to "book." Here is the script, set to post-levels 10000.
Code:
~once the user's made a selection for each of the lists, get the ~allowed spell tag from that spell if (field[usrChosen1].ischosen <> 0) then perform field[usrChosen1].chosen.pulltags[ClsAllowSp.?] endif ~ If we're not shown, just get out now doneif (tagis[Helper.ShowSpec] = 0) ~ If we're disabled, do nothing doneif (tagis[Helper.SpcDisable] <> 0) ~push those tags to the magus class, which will allow the class to ~choose those spells perform root.pushtags[ClsAllowSp.?] It worked great at 4th level, but not at all at other levels. I experimented with staggering the timing (Advanced Learning 1 at 10000, Advanced Learning 2 at 10100, etc.) but no luck there. I changed the caster type to Spellbook (Wizard ) and it works perfectly for all class abilities. For the other spellcaster types it only works the first time (4th level). I check out the forums and found someone else had this problem but they didn't post a solution or explanation. I reviewed the fields of the Class object and found the cSpellExpr and cSplBkExpr fields were affected by the "pushtags[ClsAllowSp.?] statement. Here is the expression after adding the spell Bonefiddle at 4th level: sClass.cHelpDrN | ClsAllowSp.spBonefid2 & !(sClassNot.cHelpDrN) & !.Hide.Spell & !.Hide.Obsolete & & !.Hide.Helper & !(component.EffectWord | component.MetaWord) This expression was not affected by the pushtags[ClsAllowSp.?] at the levels where advanced learning was gained (8th, 12th, etc..). I changed my script to append " | thingid.<spell id> ". This works at all levels. Can someone explain why the ClsAllowSp tagging did not work after it worked fine at 4th level. As I understand the ClsAllowSp tag, it allows a spell to added to the spell list of a class. The tag needs to be pushed to the class object "cHelp???". Thanks |
#1 |
Junior Member
Join Date: Oct 2018
Posts: 29
|
Any help on this?
|
#2 |
Senior Member
Join Date: Oct 2011
Posts: 6,793
|
Add some debugs to see if later level copies are stopping before the push, or are failing to pull.
|
#3 |
|
|