GetInputWaitTime() public static method

public static GetInputWaitTime ( Vessel vessel ) : double
vessel Vessel
return double
Beispiel #1
0
 public double GetDelayToControl(Vessel vessel)
 {
     if (!RemoteTechHook.IsAvailable(vessel.id))
     {
         return(-1); // default to no connection if the vessel isn't configured for RT.
     }
     return(RemoteTechUtility.GetInputWaitTime(vessel));
 }
        public void KOSUpdate(double deltaTime)
        {
            if (!deploymentInProgress && commandQueue.Count > 0 && !BatchMode)
            {
                waitTotal = RemoteTechUtility.GetInputWaitTime(Shared.Vessel);
                StartDeployment();
                deltaTime = 0; // so the elapsed time is zero in this update
            }

            if (deploymentInProgress)
            {
                UpdateDeployment(deltaTime);
            }
        }
        private void ProcessDeployCommand()
        {
            if (!BatchMode)
            {
                throw new Exception("Batch mode is not active.");
            }
            if (batchQueue.Count == 0)
            {
                throw new Exception("There are no commands to deploy.");
            }

            waitTotal = RemoteTechUtility.GetInputWaitTime(Shared.Vessel);
            if (double.IsPositiveInfinity(waitTotal))
            {
                throw new Exception("No connection available.");
            }

            Print("Deploying...");
            BatchMode      = false;
            deployingBatch = true;
            StartDeployment();
        }