Пример #1
0
        private void UseAbility(object sender, System.EventArgs e)
        {
            GenericUpgrade astromech = HostShip.UpgradeBar.GetInstalledUpgrades().Find(n => n.Type == UpgradeType.Astromech);

            if (astromech != null)
            {
                Sounds.PlayShipSound("R2D2-Killed");
                Messages.ShowInfo("Integrated Astromech is used");
                Messages.ShowInfo(astromech.Name + " is discarded");
                Combat.CurrentCriticalHitCard = null;
                astromech.Discard(DiscardModification);
            }
            else
            {
                Messages.ShowError("Error: No astromech to disacard!");
                SubPhases.DecisionSubPhase.ConfirmDecision();
            }
        }
Пример #2
0
        private void UseAbility(object sender, System.EventArgs e)
        {
            GenericUpgrade astromech = HostShip.UpgradeBar.GetUpgradesOnlyFaceup().Find(n => n.HasType(UpgradeType.Astromech));

            if (astromech != null)
            {
                Sounds.PlayShipSound("R2D2-Killed");
                Messages.ShowInfo("Integrated Astromech causes " + astromech.UpgradeInfo.Name + " to take a hit instead of " + HostShip.PilotInfo.PilotName);
                Messages.ShowInfo(astromech.UpgradeInfo.Name + " has been discarded");
                Combat.CurrentCriticalHitCard = null;
                astromech.Discard(DiscardModification);
            }
            else
            {
                Messages.ShowError("Error: This ship has no astromech!");
                SubPhases.DecisionSubPhase.ConfirmDecision();
            }
        }