remap-teleporters
Rewrite cross-scene teleporter destinations after scene import to fix stale IDs. Uses the import source module to map old IDs to new ones, preserving links and reporting skipped variants.
Instructions
Second pass of a scene-pack import: rewrite cross-scene teleporter destinations after the scenes + regions have been created. A pack teleporter points at Scene..Region., but the import mints FRESH ids, so every destination is stale until remapped. Pass the import sourceModule; this reconstructs the old→new scene/region id maps from the provenance flags the scenes + regions carry and rewrites every teleportToken destination. Idempotent (safe to re-run), and reports destinations that point outside the import (e.g. a variant you skipped) rather than dropping them silently. Call it ONCE after all chosen scenes are imported. GM-only.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| sourceModule | Yes | The module id stamped in flags["tom-cartos-import"].sourceModule on the imported scenes (e.g. the read-pack module.id). All scenes carrying it are scanned together. |