ModernUO/Distribution/Data/Spawns/post-uoml/trammel/WildLife.json
Kamron Batman 2f8a7afa57 chore(spawners): migrate spawn data to $type discriminator
- Rename "type" -> "$type" (first key, required for STJ polymorphism) in
  all 109 spawn JSON files (5,612 records).
- Convert "homeRange" + "location" -> "spawnBounds" object, dropping homeRange.
  Runtime keeps reading homeRange so un-migrated/external files still load.
- Add BoundsEquivalenceTests (hr=0/1/3/7) validating that the script's toBounds
  formula produces the same Rectangle3D as the runtime homeRange path.
- Add MigratedDataLoadTests loading a real migrated file as List<SpawnerDto>
  and round-tripping each DTO through ToSpawner().
- Add tools/spawner-json-migrate/migrate.mjs (offline Node script).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-25 16:17:35 -07:00

33 lines
558 B
JSON

[
{
"$type": "Spawner",
"guid": "53f1207a-7347-4899-8c9d-020fdd199822",
"name": "Spawner (126)",
"location": [
1651,
612,
22
],
"map": "Trammel",
"count": 3,
"minDelay": "00:05:00",
"maxDelay": "00:10:00",
"team": 0,
"spawnBounds": {
"x1": 1631,
"y1": 592,
"z1": -128,
"x2": 1672,
"y2": 633,
"z2": 128
},
"walkingRange": 20,
"entries": [
{
"name": "TimberWolf",
"maxCount": 3,
"probability": 100
}
]
}
]