mirror of
https://github.com/misternebula/quantum-space-buddies.git
synced 2025-01-06 10:09:31 +00:00
.
This commit is contained in:
parent
ed38e19266
commit
01c8eabce7
@ -114,20 +114,20 @@ namespace QSB.DeathSync
|
||||
{
|
||||
// Reset player position.
|
||||
var playerBody = Locator.GetPlayerBody();
|
||||
playerBody?.WarpToPositionRotation(_playerSpawnPoint.transform.position, _playerSpawnPoint.transform.rotation);
|
||||
playerBody?.SetVelocity(_playerSpawnPoint.GetPointVelocity());
|
||||
_playerSpawnPoint?.AddObjectToTriggerVolumes(Locator.GetPlayerDetector().gameObject);
|
||||
_playerSpawnPoint?.AddObjectToTriggerVolumes(_fluidDetector.gameObject);
|
||||
_playerSpawnPoint?.OnSpawnPlayer();
|
||||
playerBody.WarpToPositionRotation(_playerSpawnPoint.transform.position, _playerSpawnPoint.transform.rotation);
|
||||
playerBody.SetVelocity(_playerSpawnPoint.GetPointVelocity());
|
||||
_playerSpawnPoint.AddObjectToTriggerVolumes(Locator.GetPlayerDetector().gameObject);
|
||||
_playerSpawnPoint.AddObjectToTriggerVolumes(_fluidDetector.gameObject);
|
||||
_playerSpawnPoint.OnSpawnPlayer();
|
||||
|
||||
// Stop suffocation sound effect.
|
||||
_playerResources?.SetValue("_isSuffocating", false);
|
||||
_playerResources.SetValue("_isSuffocating", false);
|
||||
|
||||
// Reset player health and resources.
|
||||
_playerResources?.DebugRefillResources();
|
||||
_playerResources.DebugRefillResources();
|
||||
|
||||
// Remove space suit.
|
||||
_spaceSuit?.RemoveSuit(true);
|
||||
_spaceSuit.RemoveSuit(true);
|
||||
}
|
||||
|
||||
private SpawnPoint GetSpawnPoint(bool isShip = false)
|
||||
|
@ -32,7 +32,7 @@ namespace QSB.Messaging
|
||||
if (NetworkServer.handlers.Keys.Contains((short)_eventType))
|
||||
{
|
||||
DebugLog.LogState($"{_eventType} HANDLER", false);
|
||||
DebugLog.ToConsole($"Warning - NetworkServer already contains a handler for EventType {_eventType} : You probably used the wrong type in an event.", MessageType.Warning);
|
||||
DebugLog.ToConsole($"Warning - NetworkServer already contains a handler for EventType {_eventType}", MessageType.Warning);
|
||||
NetworkServer.handlers.Remove((short)_eventType);
|
||||
}
|
||||
NetworkServer.RegisterHandler((short)_eventType, OnServerReceiveMessageHandler);
|
||||
|
Loading…
Reference in New Issue
Block a user