Hello,
This is very frustrating but I had it working before with Keywordmanager.cs but now that I am trying to upgrade to Speech Input Handler I cant get things to work. Please help!
All I want to happen is upon HoloLens voice command a parent and its children objects will disappear/reappear.
I've inserted the Speech Input Source and Speech Input Manager into a manager object and the following code to be referenced by the Speech Handler within the gameobject Parent:
using System.Collections;
using System.Collections.Generic;
using HoloToolkit.Unity;
using UnityEngine;
public class HideLayer : MonoBehaviour
{
public void showHidePlane()
{
if(GetComponent().enabled == true)
{
GetComponent().enabled = false;
GetComponentInParent().enabled = false;
}
else
{
GetComponent().enabled = true;
GetComponentInParent().enabled = true;
}
}
}
Any Ideas would make my day!!
Thanks!