• Please note: In an effort to ensure that all of our users feel welcome on our forums, we’ve updated our forum rules. You can review the updated rules here: http://forums.wolflair.com/showthread.php?t=5528.

    If a fellow Community member is not following the forum rules, please report the post by clicking the Report button (the red yield sign on the left) located on every post. This will notify the moderators directly. If you have any questions about these new rules, please contact support@wolflair.com.

    - The Lone Wolf Development Team

Racial ability to improve highest caster class

I'm using the editor to design several magical races, and I would like to give them an ability with rather tricky behavior. I need two variables (which I think means two fields?), and I want the ability to behave as follows:

if the character is a member of a full-caster class,
they cast spells as if they were [var1] levels higher in their highest level caster class

if the character is not a member of a full-caster class,
they cast spells as if they were a level [var1] member of class [var2]

I am sure I can design an algorithm to do this, but I have no idea what to access and modify to implement them; it seems I need to know the following:

What classes is the character a member of, and at what levels?
Given a class, determine whether the class is a full caster (I assume this is already implemented for the purpose of multiclassing)
How can I specify a class for this ability to default to?
How can I grant spellcasting equivalent to higher level in a class? I suspect there is no easy way to do this, but is there a feasible one?
I would greatly appreciate any help with either answering these questions or using an alternate method to implement the ability. Thanks!
 
Last edited:
Lots of questions here but I'll try to help.

To add a couple of levels to Wizard for instance you can do the following in a script running pre-levels/10000 in timing.

hero.childfound[cHelpWiz].field[cCasterLev].value += 4

That snippet would add 4 effective caster levels to a PC with the Wizard class. That changes the number of spell slots, the max spell level, the spell attack bonus and spell save DC and probably the number of spells memorized (for cleric), etc... It doesn't add class features though, so if you wanted your 1st level spellrace Wizard to get the wizard tradition you select at 2nd level, you're screwed.

Now, the problems. You need to bound this at the upper side by making sure cCasterLev never goes above 20.

Your questions:
1. What classes do I have?
The easiest way to do this is to check the hero level tags. A hero will have a Classes.XXX tag where XXX is the class ID for classes it has. A Wizard with have the Classes.Wizard tag. A fighter/wizard with have Classes.Wizard and Classes.Fighter.

This equates to code like:

if (hero.tagis[Classes.Wizard) then
do stuff to wizard class items
endif

2. What levels of classes do I have?

This is in the help file of the editor. You can use #levelcount[Wizard] macro to get the total number of wizard levels.

if (#levelcount[Wizard] > 1) then
do something that only a 2nd level or higher wizard can do
endif

3. How do I specify a default class?

Well, you hardcode that as your default case? Not sure how to answer this one, if you want to default to wizard in the case of multiclassed casters, you could probably put a step in that say if you're a caster AND you have wizard, run the script for wizard and then quit, don't touch the other classes.

4. How do I?

I think given my answer up above about the field, you should be able to figure it from that and searching the forums.
 
Thanks, that really helps! Am I allowed to access the levelcount and classes before the "levels" scripts have run? If so, it looks like this should actually be pretty easy.

Hopefully I can take it from there, but I do have one question outstanding; is there some macro/function/field/etc that tells whether a class is a "full caster", meaning it's levels count fully for the purpose of multiclass spellcasting?
 
Thanks, that really helps! Am I allowed to access the levelcount and classes before the "levels" scripts have run? If so, it looks like this should actually be pretty easy.

Hopefully I can take it from there, but I do have one question outstanding; is there some macro/function/field/etc that tells whether a class is a "full caster", meaning it's levels count fully for the purpose of multiclass spellcasting?

I'm not sure, I usually use that macro post-levels, but it might just count the tags assigned. You can do a tag count on the Classes.Wizard tag, a 4th level wizard will have 4 copies of that tag before any level scripts run. I'm pretty sure there is a function to count the number of tags but I don't have my notes near me. You can probably search the forums.

#2 - on the class "helper" object are the tags you need to see if they are Full/Half/3rd/Warlock casters. This is tricky to explain.

The wizard "helper" object is cHelpWiz.

A wizard is a full caster, so the cHelpWiz object will have the Helper.FullCaster tag.

So, you have to pull the Helper tags on the class helper child objects and see if it has one of the following:
Helper.FullCaster
Helper.HalfCaster
Helper.3rdCaster
Helper.WarlocCast
 
Hey Dungeonguru, I am having a little bit of trouble implementing your advice!
I got the script to compile without errors, but it didn't seem to be actually adding the benefits, so I replaced it with just the snippet you provided:

hero.childfound[cHelpWiz].field[cCasterLev].value += 4

and it seems to not be completely effective. The "wizard spells" tab still only shows what you would expect for the one level of wizard on the hero (only allows two spells prepared and three cantrips known).The value of cHelpWiz.cCasterLev is five, and on the "spells" tab it shows the appropriate number of spells per day. Do you know how to fix this?
 
Last edited:
Back
Top