mirror of
https://github.com/MrUnknownDE/VRCX.git
synced 2026-04-30 20:23:46 +02:00
Merge overlays, move overlay to separate process (#44)
* refactor: merge two overlay offScreenBrowser into one * Electron support for shared overlay * Separate overlay into its own process * fix: invalid overlay texture size * Handle duplicate processes * Remove logging --------- Co-authored-by: pa <maplenagisa@gmail.com> Co-authored-by: rs189 <35667100+rs189@users.noreply.github.com>
This commit is contained in:
@@ -45,8 +45,7 @@ export const useVrStore = defineStore('Vr', () => {
|
||||
updateVrNowPlaying();
|
||||
// run these methods again to send data to the overlay
|
||||
sharedFeedStore.updateSharedFeed(true);
|
||||
friendStore.onlineFriendCount = 0; // force an update
|
||||
friendStore.updateOnlineFriendCounter();
|
||||
friendStore.updateOnlineFriendCounter(true); // force an update
|
||||
}
|
||||
|
||||
async function saveOpenVROption() {
|
||||
@@ -59,7 +58,6 @@ export const useVrStore = defineStore('Vr', () => {
|
||||
|
||||
function updateVrNowPlaying() {
|
||||
const json = JSON.stringify(gameLogStore.nowPlaying);
|
||||
AppApi.ExecuteVrFeedFunction('nowPlayingUpdate', json);
|
||||
AppApi.ExecuteVrOverlayFunction('nowPlayingUpdate', json);
|
||||
}
|
||||
|
||||
@@ -91,7 +89,6 @@ export const useVrStore = defineStore('Vr', () => {
|
||||
onlineFor
|
||||
};
|
||||
const json = JSON.stringify(lastLocation);
|
||||
AppApi.ExecuteVrFeedFunction('lastLocationUpdate', json);
|
||||
AppApi.ExecuteVrOverlayFunction('lastLocationUpdate', json);
|
||||
}
|
||||
|
||||
@@ -142,7 +139,6 @@ export const useVrStore = defineStore('Vr', () => {
|
||||
|
||||
/** @type {string} */
|
||||
const json = JSON.stringify(VRConfigVars);
|
||||
AppApi.ExecuteVrFeedFunction('configUpdate', json);
|
||||
AppApi.ExecuteVrOverlayFunction('configUpdate', json);
|
||||
}
|
||||
|
||||
@@ -185,6 +181,9 @@ export const useVrStore = defineStore('Vr', () => {
|
||||
newState.menuButton,
|
||||
newState.overlayHand
|
||||
);
|
||||
if (!newState.active) {
|
||||
gameStore.updateIsHmdAfk(false);
|
||||
}
|
||||
|
||||
if (LINUX) {
|
||||
window.electron.updateVr(
|
||||
|
||||
Reference in New Issue
Block a user