Jump to content

Kill Player script


metamarx

Recommended Posts

Player.getdead checks if the player is dead (which they obviously never will be since they are always alive. You usually use it to check if an npc or creature has been killed. E.g SimmsRef.getdead == 1 will check to see if Simms is dead and if he is then whatever comes next will run.

 

The kill command uses the syntax player.kill not kill player. So if you wanted to kill Simms you would go SimmsRef.kill.

 

In the future if you have simple scripting problems such as this you should first check the geck wiki for the scripting functions you are trying to use to make sure you are writing them correctly.

Link to comment
Share on other sites

Player.getdead checks if the player is dead (which they obviously never will be since they are always alive. You usually use it to check if an npc or creature has been killed. E.g SimmsRef.getdead == 1 will check to see if Simms is dead and if he is then whatever comes next will run.

 

The kill command uses the syntax player.kill not kill player. So if you wanted to kill Simms you would go SimmsRef.kill.

 

In the future if you have simple scripting problems such as this you should first check the geck wiki for the scripting functions you are trying to use to make sure you are writing them correctly.

 

player.kill crashes my game.

Link to comment
Share on other sites

  • Recently Browsing   0 members

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