Jump to content

Script Is not Working


Hicuty

Recommended Posts

I am trying to edit script form Klatu mod but it is not working as intended.

 

IF
Global("kla#AIbuff","LOCALS",400)
CheckStat(Myself,0,WIZARD_SPELL_SHIELD)
HaveSpell(WIZARD_SPELL_SHIELD) // SPWI519.SPL (Spell Shield)
THEN
RESPONSE #100
ReallyForceSpell(Myself,WIZARD_SPELL_SHIELD) // SPWI519.SPL (Spell Shield)
RemoveSpell(WIZARD_SPELL_SHIELD) // SPWI519.SPL (Spell Shield)
Continue()
END
It is casting spell shield although i have a spell shield already. I tried with CheckStatGT, it also failed. Is this a bug? Because other spells are not casted if i already have them but it is failing with spell shield.
Link to comment

Probably the CheckStat is returning a false negative. What game are you trying this on? Open SPWI519.SPL and see whether it actually sets the WIZARD_SPELL_SHIELD stat. The stat might be called something else, or the spell might set a spellstate instead of the stat, etc. etc.

 

Out of curiosity, why are you using ReallyForceSpell there?

Link to comment

Join the conversation

You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...