Beispiel #1
0
        private void AbortMissiles(bool detonate)
        {
            int abortedMissiles = 0;

            foreach (var kvp in portToMissileStatus)
            {
                if (kvp.Value.State != LaunchState.PreLaunch)
                {
                    IGC.SendUnicast(kvp.Key, new Abort()
                    {
                        Detonate = detonate
                    });
                    ++abortedMissiles;
                }
            }
            LogLine($"Aborted {abortedMissiles}, detonate: {detonate}");
        }
Beispiel #2
0
        private void LaunchMissiles(MyWaypointInfo tgt)
        {
            int launchCount = 0;

            foreach (var kvp in portToMissileStatus)
            {
                if (kvp.Value.State == LaunchState.PreLaunch)
                {
                    IGC.SendUnicast(kvp.Key, new LaunchCommand()
                    {
                        Destination = tgt.Coords
                    });
                    ++launchCount;
                }
            }
            LogLine($"Launched {launchCount} missiles to {tgt.Name} at {tgt.Coords}");
        }