Entity

The non-player things. Chess has one type: the piece. The instance update spawns the 32 of them when the game starts, and the move command is what relocates, captures and flags them. A piece therefore carries only a schema: its state is edited entirely by that command, so it needs no update files of its own.

piece

One chessman. Its fields, all sent to both clients, are the kind (pawn, knight, and so on), the color (white or black), the 0-based file and rank that place it on the board, and a moved flag the move command reads to allow a pawn's double step and castling.

[
  {
    "gamehoster-entity-schema-name": "kind",
    "gamehoster-entity-schema-type": "string",
    "gamehoster-entity-schema-sync": "sent",
    "gamehoster-entity-schema-audience": "all"
  },
  {
    "gamehoster-entity-schema-name": "color",
    "gamehoster-entity-schema-type": "string",
    "gamehoster-entity-schema-sync": "sent",
    "gamehoster-entity-schema-audience": "all"
  },
  {
    "gamehoster-entity-schema-name": "file",
    "gamehoster-entity-schema-type": "int",
    "gamehoster-entity-schema-default": 0,
    "gamehoster-entity-schema-sync": "sent",
    "gamehoster-entity-schema-audience": "all"
  },
  {
    "gamehoster-entity-schema-name": "rank",
    "gamehoster-entity-schema-type": "int",
    "gamehoster-entity-schema-default": 0,
    "gamehoster-entity-schema-sync": "sent",
    "gamehoster-entity-schema-audience": "all"
  },
  {
    "gamehoster-entity-schema-name": "moved",
    "gamehoster-entity-schema-type": "bool",
    "gamehoster-entity-schema-default": false,
    "gamehoster-entity-schema-sync": "sent",
    "gamehoster-entity-schema-audience": "all"
  }
]
chess/gamehoster-entities/piece/gamehoster-entity-schema.json