Solved Determining if player is laying or standing?
Discussion in 'Rust Development' started by Romzes, Sep 13, 2016.
-
Wulf Community Admin
You could check player.transform.rotation. Not sure what you mean by "raise the player", could you explain?
-
Is it possible you mean checking BasePlayer.IsSleeping() and BasePlayer.EndSleep()? I think these were the names of the functions, the latter would force-awake the player if that is what you want with the former checking if they are laying (sleeping)?
-
Sorry my bad english.
http://i.imgur.com/zaQgP7T.png -
BasePlayer.IsWounded() will return true if the BasePlayer object has the wounded flag, to stop them from being wounded you call BasePlayer.StopWounded()
There are also the hooks OnPlayerWound which is triggered when the player enters the wounded state and the hook OnPlayerRecover when the player recovers from the wounded state. -
Thank you! Topic can be closed.
