Bug fixes

This commit is contained in:
MrGadget1024 2023-02-18 09:14:07 -05:00
parent ab8bdb6506
commit fbc00c1ee9
3 changed files with 6 additions and 1 deletions

View File

@ -213,7 +213,7 @@ protected bool QuantizedChanged(Vector3 u, Vector3 v, float precision)
// however, OnSerialize should always delta against last. // however, OnSerialize should always delta against last.
public override void OnSerialize(NetworkWriter writer, bool initialState) public override void OnSerialize(NetworkWriter writer, bool initialState)
{ {
Debug.Log($"OnSerialize, local time: {NetworkTime.time}"); //Debug.Log($"OnSerialize, local time: {NetworkTime.time}");
// get current snapshot for broadcasting. // get current snapshot for broadcasting.
TransformSnapshot snapshot = Construct(); TransformSnapshot snapshot = Construct();

View File

@ -200,6 +200,8 @@ public override void OnClientAuthenticate()
isBot = isBot isBot = isBot
}; };
Debug.Log($"Sending: U:{playerName} N:{useNinja} M:{multiplier} B:{isBot}");
NetworkClient.Send(authRequestMessage); NetworkClient.Send(authRequestMessage);
} }

View File

@ -337,6 +337,9 @@ public override void OnStartClient()
{ {
NetworkClient.RegisterPrefab(botPrefab); NetworkClient.RegisterPrefab(botPrefab);
NetworkClient.RegisterPrefab(npcPrefab); NetworkClient.RegisterPrefab(npcPrefab);
NetworkClient.RegisterPrefab(playerNinjaPrefab);
NetworkClient.RegisterPrefab(botNinjaPrefab);
NetworkClient.RegisterPrefab(npcNinjaPrefab);
} }
/// <summary> /// <summary>