Пример #1
0
    // Update is called once per frame
    void Update()
    {
        if (!LevelObjectManager.IsDone)
        {
            return;
        }
#if KQT_ANIMS
        if (!animating)
        {
            Animations.PlayAnimationSequence("CannonIdle");
            animating = true;
        }
        if (timeSinceLastThrow > throwTime - .9f)
        {
            Animations.PlayAnimationSequence("CannonThrow"); // throwing animation is offset by about a second
        }
#endif
        if (timeSinceLastThrow > throwTime)
        { // throw goober
            Throw();
        }
        else
        {
            timeSinceLastThrow += Time.deltaTime;
        }
    }