• 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

Any Ideas...

Your character level is kept separate from your class level. There are a number of ways to do it, but the herofield[tLevel].value is your total character level. Your class level is kept on your class helper, so if you are talking Cleric, the class level is kept in hero.child[cHelpClr].field[cTotalLev].value (I think). You can find these fields by going to the Develop>Floating Info Windows>Show Selection Fields on both the Hero (totals) and the cHelpXXX appropriate helper file.

Since there is no real information on how you are trying to accomplish this, I'm making an assumption that you are using the xTurning special, and that it isn't calculating correctly. So you will need to access the hero.child[xTurning].field[Value].value and subtract the class levels, then add in the character levels. Time needs to be after Post-levels/20000.
 
Hit another road block I keep getting an error for the script:


~ If we're not shown, just get out now
doneif (tagis[Helper.SpcDisable] <> 0)

~ This character can turn undead
var result as number
result = hero.assign[Hero.TurnUndead]

~ Add our character level to our turning level.hero.child[xTurning].field[Value].value = hero.child[xTurning].field[Value].value + field[cTotalLev].value

Ideas?
 
Last edited:
Hit another road block I keep getting an error for the script:


~ If we're not shown, just get out now
doneif (tagis[Helper.SpcDisable] <> 0)

~ This character can turn undead
var result as number
result = hero.assign[Hero.TurnUndead]

This is not an error, but you can replace the use of "result" with perform:

Code:
~ This character can turn undead
perform hero.assign[Hero.TurnUndead]

~ Add our character level to our turning level.hero.child[xTurning].field[Value].value = hero.child[xTurning].field[Value].value + field[cTotalLev].value

When I copied this into my script, it didn't return correctly. Make sure you aren't commenting out part of the code. Should look like:

Code:
~ Add our character level to our turning level.
hero.child[xTurning].field[Value].value = hero.child[xTurning].field[Value].value + field[cTotalLev].value

When I did this, I was able to compile without errors.
 
Last edited:
Don't forget to bootstrap xTurning to this, otherwise it won't be able to find it and will return errors. When you get an error, it's always good practice to tell us exactly what error you get, verbatim. That way, we can help much better.
 
Back
Top