Wargame Project Design

The wargame consists of a map to represent the wargame battlefield. The wargame has counters that represent the forces involved in the historic conflict. The wargame is driven by mouse events as the map and counters are selected for action.

The map mouse move event return a hexagon name on the hexagon map. The counter mouse move event returns the counter identifier and its status. The hexagon name is calculated from the hexagon point location with the hexagon name calculator.

The map and counter mouse down events send data to the command generator. The data contains an object identifier and a hexagon location. The hexagon point location is calculated from the screen coordinates with the hexagon point calculator. The hexagon location is a x,y coordinate on the hexagon grid.

The command generator converts the event data into a game command according to the wargames game turn, phase and game mode. This is the sequence of play.

Rules use wargame calculators:

Data is managed by the wargame, force and terrain objects.

Counter are drawn using a SVG (scalable vector graphics) counter generator.