Class OfficerSelector
java.lang.Object
mekhq.campaign.universe.commandGeneration.ratgen.OfficerSelector
Ranks the people generated for a command by how well they would lead it.
The order is the one the retired AtB Company Generator used. Tactical Genius comes first: a person with the ability outranks anyone without it. After that the caller chooses which matters more, the person's combat experience level or the total of their Leadership, Strategy and Tactics skill levels; the other breaks ties. In a Clan command a Bloodname comes before everything: the Bloodnamed are the warriors the Clans put in command. The comparators here put the best person first.
-
Method Summary
Modifier and TypeMethodDescriptionstatic Comparator<Person> Orders people best first for a leadership post in a command of the campaign's own faction.static Comparator<Person> Orders people best first for a leadership post.static Comparator<Person> Orders people so the Bloodnamed come first and the rest keep their order, for a post a Clan gives only to a Bloodnamed warrior when the options ask for no other order.static StringA one-line account of what the orders see in a person, for the log: Tactical Genius if they have it, their combat experience, and their command skill total.static booleanhasBloodname(Person person) static Comparator<Person> mostSkilledFirst(Campaign campaign) Orders people best first for a seat in the leading lances: Tactical Genius, then combat experience.
-
Method Details
-
bestFirst
Orders people best first for a leadership post in a command of the campaign's own faction.- Parameters:
campaign- the campaign, whose options and date decide how skills are readprioritizeCombat-trueto rank by combat experience before command skills,falseto rank by command skills before combat experience; Tactical Genius leads either way- Returns:
- a comparator placing the best candidate first
-
bestFirst
public static Comparator<Person> bestFirst(Campaign campaign, boolean prioritizeCombat, boolean isClanCommand) Orders people best first for a leadership post.- Parameters:
campaign- the campaign, whose options and date decide how skills are readprioritizeCombat-trueto rank by combat experience before command skills,falseto rank by command skills before combat experience; Tactical Genius leads either wayisClanCommand-truewhen the command is a Clan one, so a Bloodname comes before all else- Returns:
- a comparator placing the best candidate first
-
bloodnamedFirst
Orders people so the Bloodnamed come first and the rest keep their order, for a post a Clan gives only to a Bloodnamed warrior when the options ask for no other order.- Returns:
- a comparator placing Bloodnamed people first
-
mostSkilledFirst
Orders people best first for a seat in the leading lances: Tactical Genius, then combat experience.- Parameters:
campaign- the campaign, whose options and date decide how skills are read- Returns:
- a comparator placing the most skilled pilot first
-
describe
A one-line account of what the orders see in a person, for the log: Tactical Genius if they have it, their combat experience, and their command skill total.- Parameters:
campaign- the campaign, whose options and date decide how skills are readperson- the person- Returns:
- for example
Jane Doe (Tactical Genius, combat Veteran, command 3)
-
hasBloodname
- Returns:
truewhen the person carries a Bloodname
-