- Home /
Unity GoogleVR - How do I use the GvrReticlePointer to activate a command?
Hi guys!
I'm fairly new to coding (sorry), and I'm currently working on making a Google Cardboard App that works like a powerpoint presentation. Currently, I have this script that a different user kindly provided (thank you), which allows me to change slides by pressing the Right and Left arrow keys on the keyboard.
// Update is called once per frame
void Update()
{
if (Input.GetKeyDown(KeyCode.RightArrow))
{
gameObject.SetActive(false);
NextSlide.PreviousSlide = this;
NextSlide.gameObject.SetActive(true);
}
else if (Input.GetKeyDown(KeyCode.LeftArrow) && PreviousSlide != null)
{
gameObject.SetActive(false);
PreviousSlide.gameObject.SetActive(true);
}
}
But, I want to make it so that I can change the slides by the use of the Reticle prefab. How do I make it so that instead of pressing the Right and Left arrow keys, I'd have to press a GUI or a button using the reticle?
Thanks in advance!
Your answer
![](https://koobas.hobune.stream/wayback/20220612150010im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
Google Daydream Instant Preview is not working with Unity Editor. 0 Answers
Trouble with culling mask in Google cardboard. 1 Answer
Implementing google cardboard and kudan SDK 2 Answers
Google VR (Cardboard) Distortion Incorrect on iPhone 6s 2 Answers
Left eye not rendering when setting Direct Render flag to false - iOS / Cardboard SDK 5 Answers