示例#1
0
    new void Update()
    {
        /*if (meditationStatus == MeditationStatus.meditating)
         * {
         *      elapsedTime += Time.deltaTime;
         *      if (tParam > 1.0f)
         *              meditationStatus = MeditationStatus.meditated;
         *      player.ascend ();
         * }*/

        if (meditationState == MeditationState.waitingForChispa)
        {
            if (dark)
            {
                player.meditate();
                level.musicFadeOut(5.0f);
                meditationState = MeditationState.meditating;
                fruit._wa_grow(this, timeToCompletion);
            }
            else
            {
                if (effectProgram != null)
                {
                    if (effectProgram.isProgramRunning [0])                     // wait for chispa
                    {
                        return;
                    }
                }

                fruit._wa_grow(this, timeToCompletion);
                breather.activate();
                player.meditate();
                level.musicFadeOut(10.0f);
                meditationState = MeditationState.meditating;
            }
        }

        if (meditationState == MeditationState.meditating)
        {
            if (isWaitingForActionToComplete)
            {
                return;
            }

            player.ascend();
            level.musicFadeIn();
            meditationState = MeditationState.meditated;
        }

        if (meditationState == MeditationState.meditated)
        {
        }
    }