#pragma warning restore 649 /// <summary> /// Starts up MLRaycast /// </summary> public static MLResult Start() { #if PLATFORM_LUMIN _result = MLRaycast.Start(); if (!_result.IsOk) { Debug.LogErrorFormat("Error: MLRaycastStarterKit failed starting MLRaycast. Reason: {0}", _result); } #endif return(_result); }
private void commonStart() { MLInput.OnTriggerDown += MLInput_OnTriggerDown; MLInput.OnTriggerUp += MLInput_OnTriggerUp; if (!MLRaycast.IsStarted) { MLResult raycastStart = MLRaycast.Start(); switch (raycastStart.Result) { case MLResult.Code.Ok: startRayCasting(); break; case MLResult.Code.UnspecifiedFailure: throw new System.NotImplementedException(); default: break; } } else { startRayCasting(); } }
public GameObject prefab; // Cube prefab // Use this for initialization void Start() { ctransform = transform; // Camera's transform MLRaycast.Start(); }