When I try to enter the trigger there should be a GUI Box

When I enter the trigger of the collider nothing happens. Though the boolean works but the GUI box does not appear :frowning: im using Unity 5 Hope its not a bug T-T I tried it also with OnMouseDown/Up still no avail :frowning: but when I try to use Application.LoadLevel(); it works :((((

using UnityEngine;
using System.Collections;

public class Terminal : MonoBehaviour {

public int winscreenWidth, winscreenHeight;
public bool showWinScreen = false;

void Start()
{
	}

void Update()
{
	}

public void OnTriggerEnter()
{	
	if (transform.tag == "Terminal") 
	{
		showWinScreen = true;
		//Application.LoadLevel(0);
			}
	}

public void OnTriggerExit()
{
	if (transform.tag == "Terminal") 
	{
		showWinScreen = false;
	}
}

	
void OnGui (){

	if (showWinScreen == true) {
		Rect winscreenrect = new Rect (Screen.width, Screen.height, winscreenWidth, winscreenHeight);
		GUI.Box(winscreenrect, "DAMN");
			}
			}
	}

Ok, 2 problems:

  1. the OnGUI method is spelled, OnGUI, not OnGui (capitalization matters!)

  2. you are drawing your button off the screen. Its top-left corner is currently positioned at the bottom right of the screen.