A Wesnoth-style hex army-game rules layer: terrain that costs different movement points and
grants a defence bonus per terrain kind, adjacent attacks that always let a surviving
defender strike back, capturable villages that grant income and heal whoever stands on one,
and per-side turn income built on both. Distinct from board.Tactics (an X-COM-style
action-point/cover/overwatch layer, ranged attacks, no retaliation) - this is the other
shape a hex army game needs, adjacency-only combat with a hit chance and no zone of control.
mwg supplies the mechanism only: SkirmishTerrain's move cost and defence numbers, unit
attack/hit-chance/hp values, and income rates are entirely the game's own data, the same
policy board.Army's armyIncome already follows.
constmoves = skirmishMoves(state, 'axeman'); // reachable cells, weighted by terrain cost constexchange = skirmishAttack(state, 'axeman', 'raider'); // both strike if raider survives
endSkirmishTurn(state); // hands the turn to red, refills moves, heals units on owned villages constincome = skirmishIncome(state, 'blue', 2, 1); // base 2, +1 per village blue owns
A Wesnoth-style hex army-game rules layer: terrain that costs different movement points and grants a defence bonus per terrain kind, adjacent attacks that always let a surviving defender strike back, capturable villages that grant income and heal whoever stands on one, and per-side turn income built on both. Distinct from
board.Tactics(an X-COM-style action-point/cover/overwatch layer, ranged attacks, no retaliation) - this is the other shape a hex army game needs, adjacency-only combat with a hit chance and no zone of control.mwgsupplies the mechanism only:SkirmishTerrain's move cost and defence numbers, unit attack/hit-chance/hp values, and income rates are entirely the game's own data, the same policyboard.Army'sarmyIncomealready follows.Example