Jump to content

NPC or Player won't cast spells from quest script


Recommended Posts

Quest script(clipped to just the buggy part), syntax errors might be added here, but the aren't any in the game script. General ideas presented, so no spoilers needed.

 

I need the player to autocast an SFX spell which then causes the NPC to force a chat. After the chat, the NPC will cast an SFX spell and disappear(teleport). I know how the 'goodbye' flag works, but I can't figure out to get them walk up the player and enter a chat. I'v looked up game code, but i'm still baffled. Also, I'v seen friendly NPC's cast spells. My NPC will sometimes cast it when sitting, most times nothing happens. I'v added it directly to the NPC code and same effect. ??

 

FYI, I'v had problems with using GetStageDone. So, i'm not using it.

 

 

Begin Gamemode

if getstage ALVQSancturary == 30

Player.Cast CustomSFXPlayerSpell NPC1Ref

setstage ALVQSancturary 35

endif

 

if ChatEndedFlag == 1 ;no force chat, manual

setstage ALVQSancturary 40

endif

 

if getstage ALVQSancturary == 40

NPC1Ref.cast CustomSFXNPCspell NPC1Ref

NPC1Ref.disable

setstage ALVQSancturary 45

endif

End

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...