Author Topic: How to respawn a dead player petrified? <Permanent Petrification (Very Hard)>  (Read 366 times)

Legacy_WhiteTiger

  • Hero Member
  • *****
  • Posts: 889
  • Karma: +0/-0


               

Our difficult settings configuration is to very hard but we are having troubles with the petrification.


 


If a player is petrified, the "you are death" panel appears with the message: You have been turned to stone. (this panel does not have the option to respawn).


 


The problem is when the petrified player dies, the does not disappear! The player can't respawn! 


 


How to provide the respawn possibility to petrified players when dead?


 


'<img'>



               
               

               
            

Legacy_Lightfoot8

  • Hero Member
  • *****
  • Posts: 4797
  • Karma: +0/-0


               

Are you removing effects from the player OnDeath ?    


               
               

               
            

Legacy_Lightfoot8

  • Hero Member
  • *****
  • Posts: 4797
  • Karma: +0/-0


               

It also looks like the standard PC death script uses the  PopUpGUIPanel function.  You may want to change that to the PopUpDeathGUIPanel function and set the arguments for when you want the options to appear. 



               
               

               
            

Legacy_WhiteTiger

  • Hero Member
  • *****
  • Posts: 889
  • Karma: +0/-0


               

Yes, I use PopUpDeathGUIPanel(oPC, TRUE, TRUE);


 


But the petrified players does not receive the respawn option when dead =(



               
               

               
            

Legacy_WhiteTiger

  • Hero Member
  • *****
  • Posts: 889
  • Karma: +0/-0


               

I am having trouble with the petrification. I would like to provide a respawn option when the oPC dies petrified. What I should do? Is the petrify panel bugging my on death panel?



               
               

               
            

Legacy_Proleric

  • Hero Member
  • *****
  • Posts: 1750
  • Karma: +0/-0


               It's a long time since I messed with this, but I vaguely remember that death while petrified seemed to be different by design.

Before displaying the death panel, you could loop through the effects on the PC, using RemoveEffect on EFFECT_TYPE_PETRIFY.
               
               

               
            

Legacy_Shadooow

  • Hero Member
  • *****
  • Posts: 7698
  • Karma: +0/-0


               

this doesnt happen normally, post your OnDeath script


 


as for allow respawn with petrify, I suppose that changing difficulty setting is not an option, so if you want to keep hardcore/very difficult game difficulty then you need to modify the DoPetrification function in a x0_i0_spells library and then recompile all spell/special abilities that uses this function.


 


alternatively you can allow this by sending a chat command such as !respawn or !suicide which will respawn player if petrified / kill player and triggers normal death GUI (which for some reason is meesed up for you)



               
               

               
            

Legacy_WhiteTiger

  • Hero Member
  • *****
  • Posts: 889
  • Karma: +0/-0


               

Shadooow, I found in x0_i0_spells  with thanks. I disabled the panel in the Dopetrification function


 


//DelayCommand(2.75, PopUpDeathGUIPanel(oTarget, FALSE , TRUE, 40579));


 



What all files do I need to compile that use DoPetrification?



 



if(GetIsPC(oTarget))
        {
            if(bShowPopup)
            {
                // * under hardcore rules or higher, this is an instant death
                ApplyEffectToObject(DURATION_TYPE_PERMANENT, eLink, oTarget);

                //DelayCommand(2.75, PopUpDeathGUIPanel(oTarget, FALSE , TRUE, 40579));

                // if in hardcore, treat the player as an NPC
                //bIsPC = FALSE;
                //fDifficulty = TurnsToSeconds(nPower); // One turn per hit-die
            }
            else
            {
                ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eLink, oTarget, fDifficulty);
            }
        }


               
               

               
            

Legacy_WhiteTiger

  • Hero Member
  • *****
  • Posts: 889
  • Karma: +0/-0


               

I tested with x0_s0_fleshsto (Flesh to Stone) and this worked!


 


I need to know all spells that uses DoPetrification please



               
               

               
            

Legacy_WhiteTiger

  • Hero Member
  • *****
  • Posts: 889
  • Karma: +0/-0


               

I used GREP program to search all DoPetrification in the foulder 1.71 builder resources from community patch.


 


all petrification working... =) 


Thank you so much!