Working EyeTracking with moving Hitpoint
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
using GhostSystem;
|
||||
using NUnit.Framework;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using Unity.Netcode;
|
||||
using UnityEngine;
|
||||
@@ -10,6 +11,9 @@ public class LocalPlayerReference : NetworkBehaviour
|
||||
|
||||
public List<Transform> myObjects;
|
||||
|
||||
public EyeTrackingCollisionPoints collisionPoints;
|
||||
|
||||
public static event Action OnPlayerReady;
|
||||
public override void OnNetworkSpawn()
|
||||
{
|
||||
if (IsOwner)
|
||||
@@ -27,6 +31,9 @@ public class LocalPlayerReference : NetworkBehaviour
|
||||
ghostRecorder.TrackedObjects.Add(obj);
|
||||
}
|
||||
}
|
||||
ghostRecorder.TrackedObjects.Add(collisionPoints.SpawnHitPoint());
|
||||
OnPlayerReady?.Invoke();
|
||||
Debug.LogError("Invoked OnPlayerReady");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user