Fixed EyeTracking and other Issues. Redesigned Replay UI

This commit is contained in:
Thorbjoern
2025-06-14 15:35:08 +02:00
parent 24ef9fd37b
commit 36bd205512
8 changed files with 6188 additions and 5311 deletions
+11 -3
View File
@@ -1,3 +1,6 @@
using GhostSystem;
using JetBrains.Annotations;
using Oculus.Interaction;
using System;
using System.Collections;
using System.Collections.Generic;
@@ -12,10 +15,12 @@ public class RoomManager : MonoBehaviour
public List<GameObject> portals;
public List<GameObject> enemies;
public static event Action<string> OnSceneIdReady; // um das Replay erst auszulösen, wenn die SceneId da ist, die nun über die RoomPrefs festgelegt wird.
public static event Action<string, List<GameObject>> OnSceneIdReady; // um das Replay erst auszulösen, wenn die SceneId da ist, die nun über die RoomPrefs festgelegt wird.
GhostRecorderBatch ghostRecorder;
public void Awake()
{
ghostRecorder = FindFirstObjectByType<GhostRecorderBatch>();
if (myRoom == null)
{
Debug.LogError("RoomPrefs is not assigned in RoomManager.");
@@ -25,7 +30,10 @@ public class RoomManager : MonoBehaviour
//if (!myRoom.doors && myRoom.furniture && !myRoom.portals && !myRoom.enemies) return;
if (myRoom.doors)
{
foreach (GameObject door in doors) door.SetActive(true);
foreach (GameObject door in doors)
{
door.SetActive(true);
}
}
if (!myRoom.furniture)
{
@@ -40,7 +48,7 @@ public class RoomManager : MonoBehaviour
foreach (GameObject enemy in enemies) enemy.SetActive(true);
}
sceneId = myRoom.sceneId;
OnSceneIdReady?.Invoke(sceneId);
OnSceneIdReady?.Invoke(sceneId, doors);
}
}