Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save Patola/227d2ae3185b9ffab95d807622871ee3 to your computer and use it in GitHub Desktop.

Select an option

Save Patola/227d2ae3185b9ffab95d807622871ee3 to your computer and use it in GitHub Desktop.
New Metro Awakening patch for WiVRn
From 4e7c5eee25ec047697378e060f6ff5711d6efed3 Mon Sep 17 00:00:00 2001
From: Sapphire <imsapphire0@gmail.com>
Date: Fri, 7 Nov 2025 20:41:16 -0600
Subject: [PATCH] st/oxr: push XrEventDataInteractionProfileChanged when
profile changes to NULL
---
src/xrt/state_trackers/oxr/oxr_input.c | 15 +++++++++++----
1 file changed, 11 insertions(+), 4 deletions(-)
diff --git a/src/xrt/state_trackers/oxr/oxr_input.c b/src/xrt/state_trackers/oxr/oxr_input.c
index a319e044d..cd1cd4bd9 100644
--- a/src/xrt/state_trackers/oxr/oxr_input.c
+++ b/src/xrt/state_trackers/oxr/oxr_input.c
@@ -1882,15 +1882,22 @@ oxr_session_update_action_bindings(struct oxr_logger *log, struct oxr_session *s
}
}
+ bool any_profile_changed = false;
+
#define POPULATE_PROFILE(X) \
- sess->X = XR_NULL_PATH; \
- if (profiles.X != NULL) { \
- sess->X = profiles.X->path; \
- oxr_event_push_XrEventDataInteractionProfileChanged(log, sess); \
+ { \
+ const XrPath new_path = profiles.X ? profiles.X->path : XR_NULL_PATH; \
+ if (sess->X != new_path) { \
+ sess->X = new_path; \
+ any_profile_changed = true; \
+ } \
}
OXR_FOR_EACH_VALID_SUBACTION_PATH(POPULATE_PROFILE)
#undef POPULATE_PROFILE
+ if (any_profile_changed) {
+ oxr_event_push_XrEventDataInteractionProfileChanged(log, sess);
+ }
return oxr_session_success_result(sess);
}
--
2.52.0
@LuisMayo
Copy link

LuisMayo commented Feb 7, 2026

It doesn't seem to be working for me?
[1/9] Creating directories for 'monado-populate'
[1/9] Performing download step (git clone) for 'monado-populate'
Cloning into 'monado-src'...
HEAD is now at 20e0dacbd xrt: use int64_t for timestamps in xrt_facial_expression_set*
[2/9] Performing update step for 'monado-populate'
-- Already at requested ref: 20e0dacbdd2de863923790326beec76e848b056a
[3/9] Performing patch step for 'monado-populate'
Updated 0 paths from the index
error: patch failed: src/xrt/state_trackers/oxr/oxr_input.c:1882
error: src/xrt/state_trackers/oxr/oxr_input.c: patch does not apply

This is getting ridiculous to the point I'm gonna switch to windows for this specific game... I don't know why tf monado didn't include this. Not updating wivrn is not an option either unless I manually install the client APK on the Quest so it doesn't update itself

@Patola
Copy link
Author

Patola commented Feb 8, 2026

I confirm, the patch stopped working. I will try and devise a third version but I am with very little time to do so, so it will take at least a few days, I am sorry.

@LuisMayo
Copy link

LuisMayo commented Feb 8, 2026

I will actually too, sorry if I came a bit strong in my comment, I was tired after wasting time of my weekend on this because WiVr/Montado won't care to actually make compatible software zzz

@LuisMayo
Copy link

I think you actually just uploaded the wrong patch file, after checking it. I can see the file you uploaded is just the vanilla 0007 patch from WiVrn

Here there's an updated patch: https://gist.github.com/LuisMayo/795ad9ffb9609d52f5f6c5642ac7c14b

@Patola
Copy link
Author

Patola commented Feb 10, 2026

Thanks a lot! I will reference your patch in my video once I test it for myself. :)

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