I’m making a guess the movie game, and I wondered if anybody know how I can make it so. When a person answers correctly, the button with a image on the other scene needs to change. So I need a script that changes puts a image or something over the button on the other scene. This is the script that that i need to put it in------
using UnityEngine;
using System.Collections;
using UnityEngine.UI;
using UnityEngine.SceneManagement;
public class Spawn: MonoBehaviour {
private string gameName;
private int countGuess;
[SerializeField]
private InputField input;
[SerializeField]
private Text text;
void Awake(){
gameName = "spawn";
text.text = "Guess The Name Of The Game";
}
public void GetInput(string guess){
CompareGuesses(guess);
input.text = "";
}
public void CompareGuesses (string guess){
if (guess == gameName) {
text.text = "You Guessed Correctly";
SceneManager.LoadScene("Level 1");
} else if (guess != gameName) {
text.text = "Wrong!";
} else if (guess != gameName) {
text.text = "Wrong!";
}
}
}