public void Sync(KAnimControllerBase controller)
 {
     if (!((Object)masterController == (Object)null) && !((Object)controller == (Object)null))
     {
         KAnim.Anim currentAnim = masterController.GetCurrentAnim();
         if (currentAnim != null)
         {
             KAnim.PlayMode mode        = masterController.GetMode();
             float          playSpeed   = masterController.GetPlaySpeed();
             float          elapsedTime = masterController.GetElapsedTime();
             controller.Play(currentAnim.name, mode, playSpeed, elapsedTime);
             Facing component = controller.GetComponent <Facing>();
             if ((Object)component != (Object)null)
             {
                 Vector3 position = component.transform.GetPosition();
                 float   x        = position.x;
                 x += ((!masterController.FlipX) ? 0.5f : (-0.5f));
                 component.Face(x);
             }
             else
             {
                 controller.FlipX = masterController.FlipX;
                 controller.FlipY = masterController.FlipY;
             }
         }
     }
 }