示例#1
0
文件: KSC.cs 项目: ntwest/KCT
        public void SwitchLaunchPad(int LP_ID, bool updateDestrNode = true)
        {
            const string logBlockName = nameof(SpaceCenterConstruction) + "." + nameof(SwitchLaunchPad);

            using (EntryExitLogger.EntryExitLog(logBlockName, EntryExitLoggerOptions.All))
            {
                Log.Trace("LP_ID = ".MemoizedConcat(LP_ID.MemoizedToString()));
                Log.Trace("updateDestrNode = ".MemoizedConcat(updateDestrNode.MemoizedToString()));

                //set the active LP's new state
                //activate new pad

                //LaunchPads[ActiveLaunchPadID].level = KCT_Utilities.BuildingUpgradeLevel(SpaceCenterFacility.LaunchPad);
                //LaunchPads[ActiveLaunchPadID].destroyed = !KCT_Utilities.LaunchFacilityIntact(KCT_BuildListVessel.ListType.VAB); //Might want to remove this as well
                if (updateDestrNode)
                {
                    ActiveLPInstance.RefreshDestructionNode();
                }

                if (LaunchPads.Count <= LP_ID)
                {
                    Log.Error("LaunchPads List is Missing LaunchPad ID ".MemoizedConcat(LP_ID.MemoizedToString()));
                    return;
                }

                LaunchPads[LP_ID].SetActive();
            }
        }
示例#2
0
文件: KSCItem.cs 项目: KvaNTy/RP-0
        public void SwitchLaunchPad(int LP_ID, bool updateDestrNode = true)
        {
            //set the active LP's new state
            //activate new pad

            if (updateDestrNode)
            {
                ActiveLPInstance?.RefreshDestructionNode();
            }

            LaunchPads[LP_ID].SetActive();
        }
示例#3
0
        public void SwitchLaunchPad(int LP_ID, bool updateDestrNode = true)
        {
            //set the active LP's new state
            //activate new pad

            //LaunchPads[ActiveLaunchPadID].level = KCT_Utilities.BuildingUpgradeLevel(SpaceCenterFacility.LaunchPad);
            //LaunchPads[ActiveLaunchPadID].destroyed = !KCT_Utilities.LaunchFacilityIntact(KCT_BuildListVessel.ListType.VAB); //Might want to remove this as well
            if (updateDestrNode)
            {
                ActiveLPInstance.RefreshDestructionNode();
            }

            LaunchPads[LP_ID].SetActive();
        }