Class AutoAwardsController

java.lang.Object
mekhq.campaign.personnel.autoAwards.AutoAwardsController

public class AutoAwardsController extends Object
  • Constructor Details

    • AutoAwardsController

      public AutoAwardsController()
  • Method Details

    • issueEligibleAwards

      public void issueEligibleAwards(Campaign campaign)
      Issues every award the campaign's personnel are eligible for, exactly as accepting the award ceremony unchanged would, without showing it. Shows nothing, so it is safe to call before the campaign window exists.
      Parameters:
      campaign - the campaign to be processed
    • issueAward

      public static void issueAward(Campaign campaign, Person person, Award award)
      Gives a person an award and logs it. A promotion award replaces any promotion award they already hold.
      Parameters:
      campaign - the campaign the person belongs to
      person - the person receiving the award
      award - the award
    • ManualController

      public void ManualController(Campaign campaign, boolean isManualPrompt)
      The controller for the manual-automatic processing of Awards
      Parameters:
      campaign - the campaign to be processed
    • PromotionController

      public void PromotionController(Campaign campaign, boolean isManualPrompt)
      The controller for the processing of awards prompted by a change in rank
      Parameters:
      campaign - the campaign to be processed
    • PostMissionController

      public void PostMissionController(Campaign campaign, AbstractContract mission, Boolean missionWasSuccessful, @Nullable List<Person> POWPersonnel)
      The primary controller for the automatic processing of Awards
      Parameters:
      campaign - the campaign to be processed
      mission - the mission just completed
      missionWasSuccessful - true if the Mission was a complete Success, otherwise false
      POWPersonnel - a list of persons that have been a prisoner of war in the current mission
    • PostScenarioController

      public void PostScenarioController(Campaign campaign, HashMap<UUID,Integer> personnel, HashMap<UUID,List<Kill>> scenarioKills, boolean wasCivilianHelp)
      Processes awards after a scenario is concluded.
      Parameters:
      campaign - the campaign
      personnel - the personnel involved in the scenario, mapped by their UUID
      scenarioKills - the kills made during the scenario, mapped by personnel UUID
      wasCivilianHelp - whether the scenario (if any) was AtB Scenario CIVILIAN_HELP
    • PostGraduationController

      public void PostGraduationController(Campaign campaign, List<UUID> personnel, HashMap<UUID,List<Object>> academyAttributes)
      The primary controller for the automatic processing of Training Awards
      Parameters:
      campaign - the campaign to be processed
    • prepareAwardData

      public static Map<Integer,List<Object>> prepareAwardData(UUID person, List<Award> eligibleAwards)
      This is called from within an Award Type module and prepares data for use by displayAwardCeremony()
      Parameters:
      person - the person being processed
      eligibleAwards - the Awards they are eligible for