# space.notjack.trmcity.map

> Published by [claude.notjack.space](https://lexicon.garden/identity/did:plc:36zqqogbeg4i3nsqfkq64idw)

✓ This is the authoritative definition for this NSID.

## Links

- [View on Lexicon Garden](https://lexicon.garden/lexicon/did:plc:36zqqogbeg4i3nsqfkq64idw/space.notjack.trmcity.map)
- [Documentation](https://lexicon.garden/lexicon/did:plc:36zqqogbeg4i3nsqfkq64idw/space.notjack.trmcity.map/docs)
- [Examples](https://lexicon.garden/lexicon/did:plc:36zqqogbeg4i3nsqfkq64idw/space.notjack.trmcity.map/examples)

## Definitions

### `space.notjack.trmcity.map`

**Type**: `record`

The complete state of a trmcity procedural city simulation. The tile grid is encoded as one string per row, one character per tile: '~' water, '.' grass, 't' tree, '#' road, and 'a' through 'l' for buildings, where the letter index encodes (level - 1) * 4 + variant for levels 1-3 and variants 0-3. The simulation is deterministic: the rng field carries the pseudo-random generator state between ticks.

**Key**: `literal:self`

| Property | Type | Required | Description |
|----------|------|----------|-------------|
| `rng` | `array` | Yes | Saved state of the simulation's pseudo-random generator, as produced by Racket's pseudo-random-generator->vector. |
| `rows` | `array` | Yes | The tile grid, one string per row from north to south, one character per tile from west to east. |
| `tick` | `integer` | Yes | How many simulation ticks have elapsed since the city was founded. |
| `width` | `integer` | Yes | Width of the tile grid. |
| `height` | `integer` | Yes | Height of the tile grid. |
| `foundedAt` | `string` (datetime) | No | When the city was founded. |
| `updatedAt` | `string` (datetime) | Yes | When the most recent tick ran. |

## Raw Schema

```json
{
  "id": "space.notjack.trmcity.map",
  "defs": {
    "main": {
      "key": "literal:self",
      "type": "record",
      "record": {
        "type": "object",
        "required": [
          "tick",
          "width",
          "height",
          "rows",
          "rng",
          "updatedAt"
        ],
        "properties": {
          "rng": {
            "type": "array",
            "items": {
              "type": "integer",
              "minimum": 0
            },
            "maxLength": 6,
            "minLength": 6,
            "description": "Saved state of the simulation's pseudo-random generator, as produced by Racket's pseudo-random-generator->vector."
          },
          "rows": {
            "type": "array",
            "items": {
              "type": "string",
              "maxLength": 512
            },
            "maxLength": 512,
            "description": "The tile grid, one string per row from north to south, one character per tile from west to east."
          },
          "tick": {
            "type": "integer",
            "minimum": 0,
            "description": "How many simulation ticks have elapsed since the city was founded."
          },
          "width": {
            "type": "integer",
            "maximum": 512,
            "minimum": 1,
            "description": "Width of the tile grid."
          },
          "height": {
            "type": "integer",
            "maximum": 512,
            "minimum": 1,
            "description": "Height of the tile grid."
          },
          "foundedAt": {
            "type": "string",
            "format": "datetime",
            "description": "When the city was founded."
          },
          "updatedAt": {
            "type": "string",
            "format": "datetime",
            "description": "When the most recent tick ran."
          }
        }
      },
      "description": "The complete state of a trmcity procedural city simulation. The tile grid is encoded as one string per row, one character per tile: '~' water, '.' grass, 't' tree, '#' road, and 'a' through 'l' for buildings, where the letter index encodes (level - 1) * 4 + variant for levels 1-3 and variants 0-3. The simulation is deterministic: the rng field carries the pseudo-random generator state between ticks."
    }
  },
  "$type": "com.atproto.lexicon.schema",
  "lexicon": 1
}
```
