0.11.0 • Published 3 years ago

@ttws/boardcode v0.11.0

Weekly downloads
-
License
MIT
Repository
-
Last release
3 years ago

Boardcode: DSL for board game modeling

Text format to model board states of board games.

Concepts:

  • Seat: a rectangular area on the table, dedicated to a subset of players.
  • Zones: a sub rect in a seat, that contains a certain coordinate system within.
  • Coordinate: a position in a zone, that contains a list of parts.
  • Part: a board game piece placement.

Grammar

Grammar is line-based and has these types of lines:

  • Placement: seat/zone/coord/part statement.
  • Layout: zone layout statement.
  • View: cross-seat state overrides.
  • Carry: coord/part layering rules

In addition to these, comment lines starting with // and empty lines are also allowed. The grammer is space-insensitive, and doesn't involve brackets.

Placement

There are four segments in a Placement line:

  • Zone: a path-list segment, identifying the zone to place.
  • Coord: a [a, b] part that points to a location in the zone.
  • Label: type, id, serial and copies information that identify parts.
  • State: part transformation states.

Zone/Coord/State segments carry over to remaining lines. But only lines with a Label segment actually contribute to placements.

Layout

Uses a grammar similar to Markdown Table:

| a | b |
| c | d |

Continuous rows with the same width form layout tables. Each table's first row and first column specify the row/column sizes. Use units fr and mm for relative and absolute positioning. Use ^ to expand areas from above. Areas auto-expand to the right. Use unused area codes to stop the expansion.

Commands

parsed separately. commands are word pairs that describe board changes. commands are generated by frontend and not human written directly, for now. AIs are expected to parse & generate commands in the future.

Prefabs

parsed separately. prefabs are lines of part label codes. no state codes are expected.

Views

seat::seat/public .face=down

view states are used for hidden information.

0.11.0

3 years ago

0.10.1

3 years ago

0.10.0

3 years ago

0.9.12

3 years ago

0.9.13

3 years ago

0.9.14

3 years ago

0.9.15

3 years ago

0.9.16

3 years ago

0.9.17

3 years ago

0.9.18

3 years ago

0.9.19

3 years ago

0.9.23

3 years ago

0.9.20

3 years ago

0.9.21

3 years ago

0.9.22

3 years ago

0.9.10

3 years ago

0.9.11

3 years ago

0.9.8

3 years ago

0.9.7

3 years ago

0.9.9

3 years ago

0.9.4

3 years ago

0.9.6

3 years ago

0.9.5

3 years ago

0.9.3

3 years ago

0.9.0

3 years ago

0.7.2

3 years ago

0.7.1

3 years ago

0.9.2

3 years ago

0.7.4

3 years ago

0.9.1

3 years ago

0.7.3

3 years ago

0.5.0

3 years ago

0.7.0

3 years ago

0.5.1

3 years ago

0.7.10

3 years ago

0.7.9

3 years ago

0.7.6

3 years ago

0.7.5

3 years ago

0.7.8

3 years ago

0.7.7

3 years ago

0.8.1

3 years ago

0.6.3

3 years ago

0.4.5

3 years ago

0.8.0

3 years ago

0.6.2

3 years ago

0.4.4

3 years ago

0.8.3

3 years ago

0.4.7

3 years ago

0.8.2

3 years ago

0.6.4

3 years ago

0.4.6

3 years ago

0.6.1

3 years ago

0.4.3

3 years ago

0.6.0

3 years ago

0.4.2

3 years ago

0.1.10

3 years ago

0.1.11

3 years ago

0.1.12

3 years ago

0.1.13

3 years ago

0.1.14

3 years ago

0.1.15

3 years ago

0.1.1-y

3 years ago

0.3.0

3 years ago

0.2.1

3 years ago

0.1.2

3 years ago

0.2.0

3 years ago

0.3.6

3 years ago

0.1.16

3 years ago

0.1.8

3 years ago

0.3.5

3 years ago

0.2.6

3 years ago

0.1.17

3 years ago

0.1.7

3 years ago

0.3.8

3 years ago

0.1.18

3 years ago

0.3.7

3 years ago

0.1.19

3 years ago

0.1.9

3 years ago

0.4.1

3 years ago

0.3.2

3 years ago

0.2.3

3 years ago

0.1.4

3 years ago

0.4.0

3 years ago

0.3.1

3 years ago

0.2.2

3 years ago

0.1.3

3 years ago

0.3.4

3 years ago

0.2.5

3 years ago

0.1.6

3 years ago

0.3.3

3 years ago

0.2.4

3 years ago

0.1.5

3 years ago

0.1.1

3 years ago

0.1.0

3 years ago