add_event_command
Insert an event command into an RPG Maker MZ event page, validating parameter counts to prevent structurally invalid writes; use force to override.
Instructions
Add a command to an event page. Refuses the write (nothing is saved) if the resulting page is structurally invalid — e.g. the command has the wrong parameter count for its code. Pass force: true to override.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| force | No | Write even if validation finds structural problems (wrong parameter count, unterminated command list). Off by default: such a write is refused and nothing is written. Advisory warnings never block regardless. | |
| mapId | Yes | The ID of the map | |
| dryRun | No | Preview only: return a diff of what would change without writing to disk. | |
| command | Yes | The event command to insert | |
| eventId | Yes | The ID of the event | |
| position | No | Insertion index; defaults to end of the list | |
| pageIndex | Yes | Zero-based page index |