Jump to content

[SOLVED]How to check if a player is dead in ModMain?


Recommended Posts

1 hour ago, Scrumch said:

I've just found out I can use my character's key press function while in ghost form, so what's the line to check if the player is in ghost form/dead?

inst:HasTag("playerghost") or inst.components.health:IsDead()

First part will be true when the player is entirely a ghost, second part will be true when the player's hp levels are less than zero and should be either dying or in the ghost state.

  • Thanks 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
  • Create New...