Replace UltimateXR with HurricaneVR

This commit is contained in:
2024-08-08 17:01:07 +02:00
parent e8658374d6
commit fb21dbbb73
5932 changed files with 358362 additions and 2174150 deletions

View File

@@ -0,0 +1,33 @@
using HurricaneVR.Framework.Core.ScriptableObjects;
using HurricaneVR.Framework.Core.Utils;
using HurricaneVR.Framework.Shared;
using UnityEngine;
namespace HurricaneVR.TechDemo.Scripts
{
[RequireComponent(typeof(ConfigurableJoint))]
public class DemoDummyArm : MonoBehaviour
{
public Transform Anchor;
public float Length = .5f;
public LineRenderer Rope;
public Transform ArmRopeAnchor;
void Start()
{
var joint = GetComponent<ConfigurableJoint>();
joint.SetLinearLimit(Length);
joint.anchor = ArmRopeAnchor.localPosition;
joint.autoConfigureConnectedAnchor = false;
joint.connectedAnchor = Anchor.position;
Rope.positionCount = 2;
}
// Update is called once per frame
void Update()
{
Rope.SetPosition(0, Anchor.position);
Rope.SetPosition(1, ArmRopeAnchor.position);
}
}
}