mirror of
https://github.com/GTA-ASM/SanAndreasUnity
synced 2024-11-26 22:10:17 +00:00
client uses 'loop' wrap mode for roll anim
This commit is contained in:
parent
c67acba8b2
commit
1a66200d70
1 changed files with 4 additions and 1 deletions
|
@ -37,7 +37,10 @@ namespace SanAndreasUnity.Behaviours.Peds.States
|
||||||
{
|
{
|
||||||
base.OnBecameActive();
|
base.OnBecameActive();
|
||||||
m_animState = m_model.PlayAnim( this.movementAnim );
|
m_animState = m_model.PlayAnim( this.movementAnim );
|
||||||
m_animState.wrapMode = WrapMode.Once;
|
// clients have wrap mode set to 'Loop', because state can be switched very fast between roll and crouchaim, and
|
||||||
|
// server will not update current state syncvar, so client will not start the state again,
|
||||||
|
// and roll state will remain
|
||||||
|
m_animState.wrapMode = m_isServer ? WrapMode.Once : WrapMode.Loop;
|
||||||
m_model.VelocityAxis = 0; // movement will be done along x axis
|
m_model.VelocityAxis = 0; // movement will be done along x axis
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue