diff --git a/game/Assets/Scripts/Checkpoint/SafeZone.cs b/game/Assets/Scripts/Checkpoint/SafeZone.cs index cb35084..859b957 100644 --- a/game/Assets/Scripts/Checkpoint/SafeZone.cs +++ b/game/Assets/Scripts/Checkpoint/SafeZone.cs @@ -16,6 +16,9 @@ public class SafeZone : MonoBehaviour { if (other.gameObject.CompareTag(PLAYER)) { + // set position to middle of safe zone + _respawnPosition.Value = transform.position; + // start counting safe time when we enter a safe zone _safeTime.Value = 0; } @@ -26,8 +29,6 @@ public class SafeZone : MonoBehaviour // Check if other game object is Player. if (other.gameObject.CompareTag(PLAYER)) { - _respawnPosition.Value = other.gameObject.transform.position; - // TODO: does this have implications for the time freeze ability? _safeTime.Value += Time.deltaTime; }