// Use this for initialization
    void Awake()
    {
        startingLocalPos = this.transform.localPosition;
        Instance = this;
        animations = new ArmAnimationContainer ();
        //		special = new ArmSpecialCase ();

        animator = GetComponent<Animator> ();

        ArmItemsContainer.Instance.DisableAllItems ();
        startingParent = this.transform.parent;
    }
예제 #2
0
    public void HandleAnimation(string animation)
    {
        // if there the animation doesn't exist... don't play anything so the simulation doesn't break.
        if(animation == "") {
            return;
        }

        if (inst.arms == null || inst.baby == null) {
            arms = ArmAnimatorController.Instance;
            baby = BabyAnimatorController.Instance;
        }

        arms.TriggerAnimation (animation);
        baby.TriggerAnimation (animation);
    }
예제 #3
0
 public AnimationHandler()
 {
     arms = ArmAnimatorController.Instance;
     baby = BabyAnimatorController.Instance;
 }