Example #1
0
 override public void afterOnFixedUpdate()
 {
     if (actions1.isStarted() && !actions1.isExecuted())
     {
         actions1.OnFixedUpdate();
     }
     if (actions2.isStarted() && !actions2.isExecuted())
     {
         actions2.OnFixedUpdate();
     }
 }
 override public void afterOnFixedUpdate()
 {
     if (this.condition.getConditionVerified())
     {
         actionsThen.OnFixedUpdate();
     }
     else
     {
         actionsElse.OnFixedUpdate();
     }
 }
Example #3
0
        public override void OnFixedUpdate()
        {
            //Check if we are restoring after a load
            if (HighLogic.LoadedSceneIsFlight)
            {
                if (this.activeSavepoint >= 0 && this.moduleStarted && !this.savePointJustSet)                 //We have a pending active savepoint
                {
                    //Warmup time for restoring after load
                    if (startTime > 0)
                    {
                        spendTime = initTime - (int)(Math.Round(Time.time - startTime));
                        if (spendTime <= 0)
                        {
                            this.warmingUp = false;
                            this.startTime = 0;
                            this.LoadConfig(this.selectedSlot, false, false);
                            int asp = this.activeSavepoint;
                            this.activeSavepoint = -1;
                            this.startAfterIndex(asp);
                        }
                    }
                    else
                    {
                        startTime      = Time.time;
                        this.warmingUp = true;
                    }
                }
                if (this.pendingloadBreakpoint >= 0 && this.moduleStarted)
                {
                    //Warmup time for restoring after switch
                    if (startTime > 0)
                    {
                        spendTime = initTime - (int)(Math.Round(Time.time - startTime));
                        if (spendTime <= 0)
                        {
                            this.warmingUp = false;
                            this.startTime = 0;
                            int breakpoint = this.pendingloadBreakpoint;
                            this.pendingloadBreakpoint = -1;
                            this.loadFromBreakpoint(breakpoint);
                        }
                    }
                    else
                    {
                        startTime      = Time.time;
                        this.warmingUp = true;
                    }
                }
            }

            actionsList.OnFixedUpdate();             //List action update

            //Check if we need to close the flashMessage
            if (this.flashMessageStartTime > 0f)
            {
                float flashSpendTime = (int)(Math.Round(Time.time - this.flashMessageStartTime));
                if (flashSpendTime > 5f)
                {
                    this.flashMessage                = "";
                    this.flashMessageStartTime       = 0f;
                    this.waitingDeletionConfirmation = false;
                }
            }
        }
Example #4
0
 override public void afterOnFixedUpdate()
 {
     actions.OnFixedUpdate();
 }