Skip to content

Commit 1174b40

Browse files
style - PVP
PVP-124-2 Removing trailing spaces
1 parent ab931fc commit 1174b40

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

com.unity.netcode.gameobjects/Documentation~/components/helper/networkanimator.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ private int m_GroundedParameterId;
130130
private bool m_WasGrounded;
131131
private Animator m_Animator;
132132
private CharacterController m_CharacterController;
133-
133+
134134
protected override void OnNetworkPreSpawn(ref NetworkManager networkManager)
135135
{
136136
// Pre-calculate the hash for quick lookup.
@@ -168,7 +168,7 @@ private bool m_WasGrounded;
168168
private Animator m_Animator;
169169
private NetworkAnimator m_NetworkAnimator;
170170
private CharacterController m_CharacterController;
171-
171+
172172
protected override void OnNetworkPreSpawn(ref NetworkManager networkManager)
173173
{
174174
// Pre-calculate the hash values for performance purposes.
@@ -269,7 +269,7 @@ protected override void OnNetworkPostSpawn()
269269
// Register the authority for both the Update and PostLateUpdate player loop stages
270270
// Update used to handle input and apply motion.
271271
NetworkUpdateLoop.RegisterNetworkUpdate(this, NetworkUpdateStage.Update);
272-
272+
273273
// PostLateUpdate handles camera rotation adjustments
274274
NetworkUpdateLoop.RegisterNetworkUpdate(this, NetworkUpdateStage.PostLateUpdate);
275275
_input.enabled = true;
@@ -299,7 +299,7 @@ public override void OnNetworkPreDespawn()
299299
base.OnNetworkPreDespawn();
300300
}
301301

302-
// This class implements INetworkUpdateSystem
302+
// This class implements INetworkUpdateSystem
303303
public void NetworkUpdate(NetworkUpdateStage updateStage)
304304
{
305305
if (!IsSpawned)
@@ -325,7 +325,7 @@ public void NetworkUpdate(NetworkUpdateStage updateStage)
325325
}
326326
else if (m_WasMoving)
327327
{
328-
// If synchronizing speed and we were moving, then
328+
// If synchronizing speed and we were moving, then
329329
// reset the fields used to calculate speed
330330
m_WasMoving = false;
331331
m_UnitsPerSecond = 0.0f;
@@ -349,8 +349,8 @@ private void NonAuthorityUpdate()
349349
var deltaVector3 = transform.position - m_LastPosition;
350350
// An approximated calculation of the potential unity world space units per second by getting the quotient of delta time divided into 1. We are only interested in x and z deltas, so use a Vector2, and then obtain the magnitude of the quotient times the Vector2.
351351
var unitsPerSecond = (new Vector2(deltaVector3.x, deltaVector3.z) * (1.0f / Time.deltaTime)).magnitude;
352-
353-
// Only trigger when the delta per frame exceeds the non-authority motion threshold
352+
353+
// Only trigger when the delta per frame exceeds the non-authority motion threshold
354354
if (unitsPerSecond > m_NonAuthorityMotionThreshold)
355355
{
356356
// if the new delta is > or < the last value stored
@@ -364,7 +364,7 @@ private void NonAuthorityUpdate()
364364

365365
// round speed to 3 decimal places like it does with player input
366366
_speed = (float)System.Math.Round(m_UnitsPerSecond, 3);
367-
367+
368368
// Track that we are now moving
369369
m_WasMoving = true;
370370
}
@@ -389,7 +389,7 @@ private void NonAuthorityUpdate()
389389
}
390390
// Apply the calculated speed value
391391
_animator.SetFloat(_animIDSpeed, _speed);
392-
392+
393393
}
394394
else if (m_WasMoving)
395395
{

0 commit comments

Comments
 (0)