// Use this for initialization void Start() { GetComponent <VRTK_ControllerEvents>().TouchpadPressed += new ControllerInteractionEventHandler(DoTouchpadPressed); trackedObj = GetComponent <SteamVR_TrackedObject>(); speechDisplayWidget = speechToTextHolder.GetComponent(typeof(SpeechDisplayWidget)) as SpeechDisplayWidget; keyboardDisplay = displayHolder.GetComponent(typeof(KeyboardDisplay)) as KeyboardDisplay; controllerKeyboard = controllerKeyboardHolder.GetComponent(typeof(ControllerKeyboard)) as ControllerKeyboard; }
protected void Awake() { if (instance != null) { throw new Exception("Tentative de création d'une autre instance de ControllerKeyboard alors que c'est un singleton."); } instance = this; m_player = GetComponent <Player>(); }
protected void OnDestroy() { instance = null; }