UnitLook class final

How one kind of unit looks, side by side.

Matched by UnitType.name, and that is a reading, not a rule. The simulation carries a kind as its own row of numbers precisely so that no pass has to interpret a name; drawing is the one place that wants to, because a worker and a tank are told apart on screen by shape. A kind with no look is still drawn — in StrategyVisuals.crowd, as a box — so a game that adds a fourth kind sees it on the map before it has a model.

Constructors

UnitLook({required String kind, required List<MeshLook> sides})
Dresses units of kind; sides is indexed by StrategyUnit.side, wrapping round when there are more sides than looks.
const

Properties

hashCode → int
The hash code for this object.
no setterinherited
kind → String
The UnitType.name this dresses.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
sides → List<MeshLook>
One look per side: the team colour is the difference between them.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited