Skip to content

Map inject: catch a quest area's PAC when it is read again #32

Open

Description

@sp00ktober

A map edit pushed into a quest area has to survive the area's reload: the visible mesh is built from the stage PAC when the area loads, and leaving and re-entering an area evicts the PAC and reads it again. studio map inject --catch (and the research stage_inject before it) arms a write watchpoint on the tail of the PAC's current slot, so it can re-apply the edit while the loader is stopped there.

It has never worked in game:

To do:

  • Find where the engine assigns a slot to a stage PAC it is about to (re)load, and when that happens relative to the read: the resource table mhfu.stage.resident_files reads, or the loader call.
  • Arm the catch from there: on the slot the PAC is read into, before the read.
  • Prove it live: push a camp edit, walk camp → section 1 → camp, and see the edit drawn after re-entry. The way back is mhfu rig goto (feat: hybrid ports wave 2: studio clips, walking, hit push, every clip in game, engine walls #52): one area change straight to a named point.

Done when a quest-area edit is drawn after leaving and re-entering its area, with no restart.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions