GodDamage_______Input Player Ofline -> Online
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
/// ---------------------------------------------
|
||||
/// ---------------------------------------------
|
||||
/// Ultimate Character Controller
|
||||
/// Copyright (c) Opsive. All Rights Reserved.
|
||||
/// https://www.opsive.com
|
||||
@@ -928,6 +928,15 @@ namespace Opsive.UltimateCharacterController.Character
|
||||
}
|
||||
}
|
||||
|
||||
#if ULTIMATE_CHARACTER_CONTROLLER_MULTIPLAYER
|
||||
if (m_NetworkInfo != null && !m_NetworkInfo.IsLocalPlayer()) {
|
||||
m_Up = m_Transform.up;
|
||||
m_MotorRotation = m_Transform.rotation;
|
||||
m_Torque = Quaternion.identity;
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
|
||||
base.ApplyRotation();
|
||||
}
|
||||
|
||||
@@ -989,6 +998,15 @@ namespace Opsive.UltimateCharacterController.Character
|
||||
m_ActiveItemAbilities[i].ApplyPosition();
|
||||
}
|
||||
|
||||
#if ULTIMATE_CHARACTER_CONTROLLER_MULTIPLAYER
|
||||
if (m_NetworkInfo != null && !m_NetworkInfo.IsLocalPlayer()) {
|
||||
m_Velocity = (m_Transform.position - m_PrevPosition) / (m_TimeScale * Time.deltaTime);
|
||||
m_PrevPosition = m_Transform.position;
|
||||
m_MoveDirection = Vector3.zero;
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
|
||||
base.ApplyPosition();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user