• 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

Warlock Spell Slots

spannclann

Well-known member
I have chosen to give a class limited spell slots so I used the Warlock spell slots. When I print out the character sheet, the spell slots are listed as Warlock. Is there any way to change this with some sort of name change command?
 

Attachments

  • Screenshot 2023-07-13 214140.png
    Screenshot 2023-07-13 214140.png
    58.3 KB · Views: 4
I have chosen to give a class limited spell slots so I used the Warlock spell slots. When I print out the character sheet, the spell slots are listed as Warlock. Is there any way to change this with some sort of name change command?

Final/100000

hero.child[thingid].field[livename].text = "New Name Here"
 
@RavenX

Ive tried both of these but it has not changed anything. What could I be doing wrong?

hero.child[SlotHoldWa].field[livename].text = "New Name Here"

hero.child[SpellSlots].field[livename].text = "New Name Here"

I have also tried to replace the text but no luck

hero.child[SlotHoldWa].field[livename].text = replace(hero.child[SlotHoldWa].field[livename].text, "Warlock", "Fabled Archer", 0)
 
Last edited:
Any thoughts or ideas? Anyone?

I am putting this name changing script in the Class Special ability. Is that the place for it? I also have it with three other eval scripts. Should they be in another order than this?
1. Makes the Hero a Caster
2. Sets INT as the spell casting stat
3. Gives the Hero Warlock spell slots
4. Tries to change the Spell Slot name from Warlock to "New Name" when the character sheet is printed.
 
Last edited:
@RavenX

Ive tried both of these but it has not changed anything. What could I be doing wrong?

hero.child[SlotHoldWa].field[livename].text = "New Name Here"

hero.child[SpellSlots].field[livename].text = "New Name Here"

I have also tried to replace the text but no luck

hero.child[SlotHoldWa].field[livename].text = replace(hero.child[SlotHoldWa].field[livename].text, "Warlock", "Fabled Archer", 0)

Phase and Priority. You need this in Render phase with a late priority to overwrite whatever livename script is already present in the source code. Try a priority of 100000 and see if that helps. Livename is a field that auto generates at a certain phase so if its not changing to what you set it to, then you're changing the field too early.

Hero Lab works through each phase one at a time. It compiles the code from the lowest priority number to the highest in each phase.

So it basically parses Initialize from 0 to 99999999 then moves to Setup and does the same thing parsing the code for each phase individually.

If you are setting in say Final 1000, and another script is running in Render 10000, the Render script will overwrite what you did. Your script has to run later than Render 10000 if you want to make the change you did work.
 
Okay, I have got it to work somewhat. It has changed in Hero Lab, but not on the printed character sheet.
 

Attachments

  • 1.png
    1.png
    57.4 KB · Views: 2
  • 2.png
    2.png
    84.3 KB · Views: 2
Okay, I have got it to work somewhat. It has changed in Hero Lab, but not on the printed character sheet.

Try running the script later like 99999999 and see if that fixes the sheet output, if it doesn't then there's an issue with the way sheet output was setup. You can't change sheet output without having full access to the structure files themselves.
 
I already checked for you on the source code and it is locked down, so the changes to sheet output you need would have to be done by someone who works for Lone Wolf if changing the livename doesn't work. They might have coded the source code for sheets to output the name field instead of the livename field.
 
Back
Top