Пример #1
0
 public override void ComponentOnEnable()
 {
     CacheNetTransform.enabled            = true;
     CacheOpenCharacterController.enabled = true;
     CacheOpenCharacterController.SetPosition(CacheTransform.position, true);
     tempVerticalVelocity          = 0;
     CacheNetTransform.onTeleport += OnTeleport;
 }
Пример #2
0
 public override void EntityStart()
 {
     yRotation              = CacheTransform.eulerAngles.y;
     tempCurrentPosition    = CacheTransform.position;
     tempCurrentPosition.y += GROUND_BUFFER;
     CacheOpenCharacterController.SetPosition(tempCurrentPosition, true);
     tempVerticalVelocity = 0;
 }
Пример #3
0
 protected void OnTeleport(Vector3 position, Quaternion rotation)
 {
     CacheOpenCharacterController.SetPosition(position, true);
     tempVerticalVelocity = 0;
 }