Author Topic: Resurrection wand is not always working  (Read 333 times)

Legacy_Fallyn Rayne

  • Newbie
  • *
  • Posts: 34
  • Karma: +0/-0
Resurrection wand is not always working
« on: April 02, 2012, 06:00:15 pm »


               Hi. My module, Gladiatrix II,  is in beta testing. There is a wand of resurrection in the module that can be used to revive hencmen. My testers have noticed that the wand doesn't always work. The raise dead animation happens but the henchman is still dead. When I went back and tested it seems to work sporadically.

The wand has the following property:
Cast Spell: Resurrection (13)

I'm using X2_hen_death script and the x2 henchmen script set on the henchmen.

I can't for the life of me determine why this only works sporadically. Is the resurrection script activated somewhere other than the npc death script, such as a module event property? Is there a way I can set it to make it work all the time? Does anyone have any idea why this only happens sporadically?

Any help would be greatly appreciated because I'm really stumped on this. Thanks
               
               

               
            

Legacy_Failed.Bard

  • Hero Member
  • *****
  • Posts: 1409
  • Karma: +0/-0
Resurrection wand is not always working
« Reply #1 on: April 02, 2012, 06:10:56 pm »


               NPCs have to be set specifically to be able to be raised/resurrected.  This is best set in the creatures OnSpawn script.  The command you need is:

void SetIsDestroyable(int bDestroyable, int bRaiseable = TRUE, int bSelectableWhenDead = FALSE);

Parameters:

bDestroyable
If this is FALSE, the caller does not fade out on death, but sticks around as a corpse.

bRaiseable
If this is TRUE, the caller can be raised via resurrection. (Default: TRUE)

bSelectableWhenDead
If this is TRUE, the caller is selectable after death. (Default: FALSE)