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;
             }
         }
     }
 }
 public void AddAccessory(Accessory accessory)
 {
     if (accessory != null)
     {
         SymbolOverrideController component = animController.GetComponent <SymbolOverrideController>();
         component.AddSymbolOverride(accessory.slot.targetSymbolId, accessory.symbol, 0);
         if (!HasAccessory(accessory))
         {
             ResourceRef <Accessory> resourceRef = new ResourceRef <Accessory>(accessory);
             if (resourceRef != null)
             {
                 accessories.Add(resourceRef);
             }
         }
     }
 }
    private void AddAnimTracker(GameObject go)
    {
        KAnimControllerBase component = go.GetComponent <KAnimControllerBase>();

        if (!((Object)component == (Object)null) && component.AnimFiles != null && component.AnimFiles.Length > 0 && (Object)component.AnimFiles[0] != (Object)null && component.GetComponent <Pickupable>().trackOnPickup)
        {
            KBatchedAnimTracker kBatchedAnimTracker = go.AddComponent <KBatchedAnimTracker>();
            kBatchedAnimTracker.useTargetPoint     = false;
            kBatchedAnimTracker.fadeOut            = false;
            kBatchedAnimTracker.symbol             = new HashedString("snapTo_chest");
            kBatchedAnimTracker.forceAlwaysVisible = true;
        }
    }