Upload files to "Classes"

This commit is contained in:
Deez committed 2026-11-26 14:41:09 -05:00
1 parent 520d582c8c
commit 35a1f0d2de
2 files changed
+158

No files matched your search

+27
View File
@@ -0,0 +1,27 @@
using UnityEngine;
namespace GorillaCaptions.Classes
{
public class SpeechBubble : MonoBehaviour
{
public VRRig Owner;
private GameObject uiTarget;
private float spawnTime;
void Awake()
{
spawnTime = Time.time;
uiTarget = transform.Find("Canvas").gameObject;
gameObject.transform.localPosition = Vector3.up * 0.6f;
}
void Update()
{
if (Time.time > spawnTime + 10f || Owner == null || !Owner.gameObject.activeInHierarchy)
Managers.BubbleManager.instance.DestroyBubble(gameObject);
}
void LateUpdate() =>
uiTarget.transform.LookAt(GorillaTagger.Instance.headCollider.transform.position);
}
}