[PR #195] [MERGED] examples: Portal 2 portal gun in Outer Wilds (OWML) + field notes #199

Closed
opened 2026-10-15 20:54:15 +00:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/rehan-remade/universal-modder/pull/195
Author: @charlystereo
Created: 10/10/2026
Status: ✅ Merged
Merged: 10/11/2026
Merged by: @rehan-remade

Base: main ← Head: outer-wilds-portal-gun


📝 Commits (5)

  • b933773 Add Portal 2 portal gun for Outer Wilds example and field notes
  • 8390381 MODLOG: drop the user's profile name
  • 76f8556 kb: Outer Wilds portal gun: review fixes
  • f534157 Merge remote-tracking branch 'origin/main' into land/pr-195
  • 4e4170c kb: regenerate the index

📊 Changes

26 files changed (+4041 additions, -9 deletions)

View changed files

📝 AGENTS.md (+1 -1)
➕ examples/outer-wilds-portal-gun/.gitignore (+4 -0)
➕ examples/outer-wilds-portal-gun/MODLOG.md (+112 -0)
➕ examples/outer-wilds-portal-gun/README.md (+81 -0)
➕ examples/outer-wilds-portal-gun/src/DevBridge.cs (+434 -0)
➕ examples/outer-wilds-portal-gun/src/GunAssets.cs (+187 -0)
➕ examples/outer-wilds-portal-gun/src/Materials.cs (+179 -0)
➕ examples/outer-wilds-portal-gun/src/OWPortalGun.csproj (+25 -0)
➕ examples/outer-wilds-portal-gun/src/Portal.cs (+234 -0)
➕ examples/outer-wilds-portal-gun/src/PortalGun.cs (+461 -0)
➕ examples/outer-wilds-portal-gun/src/PortalGunMod.cs (+138 -0)
➕ examples/outer-wilds-portal-gun/src/PortalHud.cs (+68 -0)
➕ examples/outer-wilds-portal-gun/src/PortalSystem.cs (+662 -0)
➕ examples/outer-wilds-portal-gun/src/Viewmodel.cs (+199 -0)
➕ examples/outer-wilds-portal-gun/src/default-config.json (+25 -0)
➕ examples/outer-wilds-portal-gun/src/manifest.json (+10 -0)
➕ examples/outer-wilds-portal-gun/tools/convert.py (+266 -0)
➕ examples/outer-wilds-portal-gun/tools/source_mdl.py (+304 -0)
➕ examples/outer-wilds-portal-gun/tools/vpk.py (+96 -0)
➕ examples/outer-wilds-portal-gun/tools/vtf.py (+69 -0)

...and 6 more files

📄 Description

Adds examples/outer-wilds-portal-gun and three knowledge-base notes from a session that put Portal 2's portal gun into Outer Wilds 1.1.16 (Steam) through OWML 2.16.3.

What's in it

  • OWML mod (C#, HarmonyX): key 5 takes the gun out in any save, from the first second of each loop, with or without the suit. Left mouse places blue, right mouse places orange, and the wheel changes portal size (up to ship size).
    • Portals show the other side: a stencil mask through UI/Default plus an oblique camera, scissored to the portal's screen rect.
    • They keep momentum relative to the bodies they're attached to and stick to whatever they hit.
    • They clear at loop reset.
    • The player, the scout and the ship can travel through.
  • Converter (Python): reads the user's own Portal 2 install and converts the gun's model, textures and sounds on their machine, so nothing from Valve is in the repo.
    • Formats: VPK v2, MDL v49 + VVD + VTX with compressed animations, VTF, WAV.
  • Mod-side command bridge: an oracle that runs the game from the title screen to a lab profile, wake-up and repeatable tests without touching input.
  • Notes:
    • games/outer-wilds/…: versions, the route, the engine facts we needed, and 16 gotchas.
    • games/portal-2/…: struct sizes and the animation and texture formats.
    • techniques/…: the command-file test bridge.
  • AGENTS.md lists the new example. INDEX.md and index.json are regenerated (adds these 3 notes only).

Verified in the real game

Verified with screenshots, 20 Hz traces and the OWML log:

  • floor↔floor and wall↔floor travel with speed kept and the player upright;
  • the ship dropped into a portal comes out of a wall portal at 25.8 m/s;
  • the scout goes through at 48 m/s;
  • after a loop reload the portals are gone and the gun is back;
  • with real SendInput: key 5, left click and right click work, and the scout launcher isn't triggered.

Not verified: loose physics props (same code path as the ship), moving islands, other planets, gamepad.

Checks

  • um kb check --index: PASS (131 notes).
  • um publish check .: 0 failures. The 2 warnings are in existing notes.
  • pytest tests: 76 passed, 1 failed. The failure is test_compile_small_edl, a WinError from ffmpeg on this Windows machine; um/ is untouched.

🤖 Generated with Claude Code


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/rehan-remade/universal-modder/pull/195 **Author:** [@charlystereo](https://github.com/charlystereo) **Created:** 10/10/2026 **Status:** ✅ Merged **Merged:** 10/11/2026 **Merged by:** [@rehan-remade](https://github.com/rehan-remade) **Base:** `main` ← **Head:** `outer-wilds-portal-gun` --- ### 📝 Commits (5) - [`b933773`](https://github.com/rehan-remade/universal-modder/commit/b93377317d5f64d016a370828f271ec70e237291) Add Portal 2 portal gun for Outer Wilds example and field notes - [`8390381`](https://github.com/rehan-remade/universal-modder/commit/839038112f352c9922c32c1bc9f796d43951b824) MODLOG: drop the user's profile name - [`76f8556`](https://github.com/rehan-remade/universal-modder/commit/76f855695e0b89920e56f480ba6cea3d3ad4fcb4) kb: Outer Wilds portal gun: review fixes - [`f534157`](https://github.com/rehan-remade/universal-modder/commit/f5341573ebde4a5a1b5b2629bc97ac90f69b68f0) Merge remote-tracking branch 'origin/main' into land/pr-195 - [`4e4170c`](https://github.com/rehan-remade/universal-modder/commit/4e4170cd23fbae247f7d5188901702dbea9f8a5e) kb: regenerate the index ### 📊 Changes **26 files changed** (+4041 additions, -9 deletions) <details> <summary>View changed files</summary> 📝 `AGENTS.md` (+1 -1) ➕ `examples/outer-wilds-portal-gun/.gitignore` (+4 -0) ➕ `examples/outer-wilds-portal-gun/MODLOG.md` (+112 -0) ➕ `examples/outer-wilds-portal-gun/README.md` (+81 -0) ➕ `examples/outer-wilds-portal-gun/src/DevBridge.cs` (+434 -0) ➕ `examples/outer-wilds-portal-gun/src/GunAssets.cs` (+187 -0) ➕ `examples/outer-wilds-portal-gun/src/Materials.cs` (+179 -0) ➕ `examples/outer-wilds-portal-gun/src/OWPortalGun.csproj` (+25 -0) ➕ `examples/outer-wilds-portal-gun/src/Portal.cs` (+234 -0) ➕ `examples/outer-wilds-portal-gun/src/PortalGun.cs` (+461 -0) ➕ `examples/outer-wilds-portal-gun/src/PortalGunMod.cs` (+138 -0) ➕ `examples/outer-wilds-portal-gun/src/PortalHud.cs` (+68 -0) ➕ `examples/outer-wilds-portal-gun/src/PortalSystem.cs` (+662 -0) ➕ `examples/outer-wilds-portal-gun/src/Viewmodel.cs` (+199 -0) ➕ `examples/outer-wilds-portal-gun/src/default-config.json` (+25 -0) ➕ `examples/outer-wilds-portal-gun/src/manifest.json` (+10 -0) ➕ `examples/outer-wilds-portal-gun/tools/convert.py` (+266 -0) ➕ `examples/outer-wilds-portal-gun/tools/source_mdl.py` (+304 -0) ➕ `examples/outer-wilds-portal-gun/tools/vpk.py` (+96 -0) ➕ `examples/outer-wilds-portal-gun/tools/vtf.py` (+69 -0) _...and 6 more files_ </details> ### 📄 Description Adds `examples/outer-wilds-portal-gun` and three knowledge-base notes from a session that put Portal 2's portal gun into Outer Wilds 1.1.16 (Steam) through OWML 2.16.3. ## What's in it - **OWML mod (C#, HarmonyX):** key 5 takes the gun out in any save, from the first second of each loop, with or without the suit. Left mouse places blue, right mouse places orange, and the wheel changes portal size (up to ship size). - Portals show the other side: a stencil mask through `UI/Default` plus an oblique camera, scissored to the portal's screen rect. - They keep momentum relative to the bodies they're attached to and stick to whatever they hit. - They clear at loop reset. - The player, the scout and the ship can travel through. - **Converter (Python):** reads the user's own Portal 2 install and converts the gun's model, textures and sounds on their machine, so nothing from Valve is in the repo. - Formats: VPK v2, MDL v49 + VVD + VTX with compressed animations, VTF, WAV. - **Mod-side command bridge:** an oracle that runs the game from the title screen to a lab profile, wake-up and repeatable tests without touching input. - **Notes:** - `games/outer-wilds/…`: versions, the route, the engine facts we needed, and 16 gotchas. - `games/portal-2/…`: struct sizes and the animation and texture formats. - `techniques/…`: the command-file test bridge. - `AGENTS.md` lists the new example. `INDEX.md` and `index.json` are regenerated (adds these 3 notes only). ## Verified in the real game Verified with screenshots, 20 Hz traces and the OWML log: - floor↔floor and wall↔floor travel with speed kept and the player upright; - the ship dropped into a portal comes out of a wall portal at 25.8 m/s; - the scout goes through at 48 m/s; - after a loop reload the portals are gone and the gun is back; - with real SendInput: key 5, left click and right click work, and the scout launcher isn't triggered. Not verified: loose physics props (same code path as the ship), moving islands, other planets, gamepad. ## Checks - `um kb check --index`: PASS (131 notes). - `um publish check .`: 0 failures. The 2 warnings are in existing notes. - `pytest tests`: 76 passed, 1 failed. The failure is `test_compile_small_edl`, a WinError from ffmpeg on this Windows machine; `um/` is untouched. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-15 20:54:15 +00:00
Sign in to join this conversation.
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
rehan-remade/universal-modder#199
No description provided.