Class UnitReroller
A player who does not want the Locust a lance rolled can ask for another unit in its place without rolling the whole lance again. The new unit is drawn for the same slot: the same unit type, weight class, movement mode and role, from the same faction table. It is never the design being replaced. If the formation has rules - a Recon lance that needs fast units, say - the new unit must leave the formation still meeting them. When nothing does, the slot keeps the unit it had.
A formation that fields one design in every slot - an artillery battery, a company of one model - is no exception. Only the unit picked is swapped, so it no longer matches its formation-mates, which keep the design they share. The player asked for that unit to go, and redrawing the whole formation is what Change Formation is for.
The pilot stays: the slot's commander is put in the new unit. The slot is also brought back into the force if it had been struck out, since striking a unit out and rerolling it both say the player did not want that unit.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordWhat a reroll did.static enumWhy a node cannot be rerolled as a single unit. -
Method Summary
Modifier and TypeMethodDescriptionstatic UnitReroller.Outcomereroll(ForceDescriptor slot) Replaces the unit in one slot with another drawn for the same slot.static UnitReroller.RefusalSays whether a node can be rerolled as a single unit.
-
Method Details
-
whyNotRerollable
Says whether a node can be rerolled as a single unit.- Parameters:
slot- the node the player picked- Returns:
- why it cannot, or
nullwhen it can
-
reroll
Replaces the unit in one slot with another drawn for the same slot.- Parameters:
slot- the node holding the unit to replace- Returns:
- what was done, or
nullwhen the slot cannot be rerolled or nothing else fits it; the slot is left exactly as it was in that case
-