Fix DisableInput bug

This commit is contained in:
Sofia 2020-08-10 03:19:21 +03:00
parent 186c84ee62
commit 77c2de6083
1 changed files with 1 additions and 1 deletions

View File

@ -221,7 +221,7 @@ namespace NeonTea.Quakeball.Players {
/// <summary>Called when this Player is respawned, after dying.</summary>
public void Respawn(Vector3 location) {
if (Net.Singleton.Instance != null && Net.Singleton.Instance.LocalPlayer.Id == NetId) {
if (Net.Singleton.Instance != null && Net.Singleton.Instance.LocalPlayer.Id == NetId && IsDead) {
GameObject.FindGameObjectWithTag("DeadScreen").GetComponent<DeadScreen>().Open = false;
Net.Singleton.Instance.LocalPlayer.Controlled.GetComponent<LocalPlayer>().DisableInput -= 1;
}