set_encounters
Set a map's random encounters and average step count. Validates every troop ID, replacing any existing list.
Instructions
Set a map's random-encounter list (replaces it wholesale) and optionally its encounterStep (average steps between encounters). Each encounter is { troopId, weight?, regionSet? }: weight biases the random pick (default 5), regionSet restricts it to those map region ids (empty/omitted = anywhere). Every troopId is validated against Troops.json — a non-existent troop throws. Prefer this over update_map for encounters (it validates and hides the on-disk shape).
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"mapId": "<mapId>",
"encounters": "<encounters>"
},
"name": "set_encounters"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| mapId | Yes | The ID of the map | |
| dryRun | No | Preview only: return a diff of what would change without writing to disk. | |
| encounters | Yes | The full encounter list to set (replaces any existing entries) | |
| encounterStep | No | Average number of steps between encounters (unchanged if omitted) |