private void PerformFreeAction(object sender, System.EventArgs e) { HostShip.GenerateAvailableActionsList(); List <ActionsList.GenericAction> actions = Selection.ThisShip.GetAvailableActionsList(); HostShip.AskPerformFreeAction(actions, Triggers.FinishTrigger); }
private void UseAdvancedSensors(object sender, System.EventArgs e) { HostShip.GenerateAvailableActionsList(); List <ActionsList.GenericAction> actions = HostShip.GetAvailableActionsList(); HostShip.AskPerformFreeAction(actions, SubPhases.DecisionSubPhase.ConfirmDecision); // if ability is used, skipped Perform Action HostShip.IsSkipsActionSubPhase = true; }
private void PerformAction(object sender, System.EventArgs e) { HostShip.GenerateAvailableActionsList(); List <GenericAction> actions = Selection.ThisShip.GetAvailableActionsList(); HostShip.BeforeFreeActionIsPerformed += PayForceCost; Messages.ShowInfo("Darth Vader: you may spend 1 force to perform an action"); HostShip.AskPerformFreeAction(actions, CleanUp); }
private void DeathfireEffect(object sender, EventArgs e) { HostShip.GenerateAvailableActionsList(); var actions = HostShip.GetAvailableActionsList() .Where(action => action is BombDropAction) .ToList(); HostShip.AskPerformFreeAction(actions, () => { ClearIsAbilityUsedFlag(); Triggers.FinishTrigger(); }); }
private void PerformFreeAction(object sender, System.EventArgs e) { HostShip.GenerateAvailableActionsList(); var previousSelectedShip = Selection.ThisShip; Selection.ThisShip = HostShip; HostShip.AskPerformFreeAction(HostShip.GetAvailableActionsList(), delegate { Selection.ThisShip = previousSelectedShip; Triggers.FinishTrigger(); }); }