diff --git a/QSB/DeathSync/RespawnOnDeath.cs b/QSB/DeathSync/RespawnOnDeath.cs index c2d096e3..72d5de07 100644 --- a/QSB/DeathSync/RespawnOnDeath.cs +++ b/QSB/DeathSync/RespawnOnDeath.cs @@ -59,7 +59,7 @@ namespace QSB.DeathSync { if (_shipSpawnPoint == null) { - DebugLog.ToConsole("_shipSpawnPoint is null!", MessageType.Warning); + DebugLog.ToConsole("Warning - _shipSpawnPoint is null!", MessageType.Warning); Init(); } @@ -95,6 +95,12 @@ namespace QSB.DeathSync public void ResetPlayer() { + if (_shipSpawnPoint == null) + { + DebugLog.ToConsole("Warning - _playerSpawnPoint is null!", MessageType.Warning); + Init(); + } + // Reset player position. var playerBody = Locator.GetPlayerBody(); playerBody.WarpToPositionRotation(_playerSpawnPoint.transform.position, _playerSpawnPoint.transform.rotation); diff --git a/QSB/QSBNetworkManager.cs b/QSB/QSBNetworkManager.cs index fd7cb362..00861d28 100644 --- a/QSB/QSBNetworkManager.cs +++ b/QSB/QSBNetworkManager.cs @@ -180,8 +180,6 @@ namespace QSB gameObject.AddComponent(); gameObject.AddComponent(); - QSBCore.Helper.Events.Unity.RunWhen(() => QSBCore.HasWokenUp, RespawnOnDeath.Instance.Init); - if (QSBSceneManager.IsInUniverse) { QSBSectorManager.Instance.RebuildSectors();