Aller au contenu

Photo

No respawning in a module


  • Veuillez vous connecter pour répondre
4 réponses à ce sujet

#1
MasterOFMorag

MasterOFMorag
  • Members
  • 7 messages
Hey all. I was just wondering if there's a script that will prevent people from respawning in a module.
Thanks in advance.

#2
WhiZard

WhiZard
  • Members
  • 1 204 messages

MasterOFMorag wrote...

Hey all. I was just wondering if there's a script that will prevent people from respawning in a module.
Thanks in advance.


This command is used in the default on-death script.  It has parameters to disallow respawning and waiting for help.

void PopUpDeathGUIPanel(object oPC, int bRespawnButtonEnabled=TRUE, int bWaitForHelpButtonEnabled=TRUE, int nHelpStringReference=0, string sHelpString="")

EDIT: Looks like the standard on death uses PopUpGUIPanel() instead, a much more limiting command for the death panel.  Replace this command with the more flexible PopUpDeathGUIPanel().

Modifié par WhiZard, 23 février 2012 - 03:36 .


#3
MasterOFMorag

MasterOFMorag
  • Members
  • 7 messages
Thanks for the reply, but I've got a problem. When I compile the script it says this: ERROR: UNKNOWN STATE IN COMPILER

#4
GhostOfGod

GhostOfGod
  • Members
  • 863 messages
If you still want a window to pop up with default text you would use this:

DelayCommand(2.5, PopUpDeathGUIPanel(oPlayer,FALSE, TRUE, 66487));


You could also use the pop up with your own text. Something like so:

DelayCommand(2.5, PopUpDeathGUIPanel(oPlayer,FALSE, TRUE, 0, "You're dead sucka!"));

(Also note with the function "PopUpDeathGUIPanel", if it is a single player module you won't see the wait button. Only quit game or load game)


And then of course you could get rid of the pop up window all together and just let the player hit the escape key by getting rid of the line or I recommend just commenting it out:

//DelayCommand(2.5, PopUpDeathGUIPanel(oPlayer,FALSE, TRUE, 66487));


Hope it helps clear things up.

Modifié par GhostOfGod, 23 février 2012 - 08:59 .


#5
MasterOFMorag

MasterOFMorag
  • Members
  • 7 messages
thanks or the feedback. It works perfectly!