I want to know the lines of script to add on in order that when the player health = 0 or is destroyed, a GUIbutton is shown. I have tried to do this but it does not work. Here are the exerpts from my script-
Thanks,
void Update(){
health += Input.GetAxisRaw("Horizontal");
if (health < 0){
health = 0;
destroy = true;
Destroy();
}
void Destroy(){
if(GUI.Button(new Rect(100, 100, 100, 100),"Level Complete")){
Application.LoadLevel(1);
}