Texture doesn't show up on the Rift
Since I just want a static GUI (no interaction) to pop up whenever I come close to an object, I work with textures.
Here I have this javascript that works well on non-VR projects:
It basically shows or hides the texture when colliding with an invisible cube. Working perfectly on projects that use a normal camera.
What changes should I make so that the Rift displays this texture? I don't understand why it doesn't show up because it's not even a real GUI o.o
Here I have this javascript that works well on non-VR projects:
#pragma strict
private var guiShow : boolean = false;
var riddle : Texture;
function OnTriggerStay (Col : Collider)
{
if(Col.tag == "Player")
{
guiShow = true;
}
}
function OnTriggerExit (Col : Collider)
{
if(Col.tag == "Player")
{
guiShow = false;
}
}
function OnGUI()
{
if(guiShow == true)
{
GUI.DrawTexture(Rect(Screen.width/4, Screen.height/4, 1000,500),riddle);
}
}
It basically shows or hides the texture when colliding with an invisible cube. Working perfectly on projects that use a normal camera.
What changes should I make so that the Rift displays this texture? I don't understand why it doesn't show up because it's not even a real GUI o.o
