Hey all I’ve been having a problem with unity.
My Unity hasn’t been liking the section of coding “loadingImage.SetActive(true);” saying “UnassignedReferenceException: The variable loadingImage of LoadOnClick has not been assigned.” I am unsure as to what to do in this instance as i haven’t had this problem before in Unity 5.1.0 the entire section of coding is at the bottom i wanted to ask if anyone could please help me with this thanks.
using UnityEngine;
using System.Collections;
public class LoadOnClick : MonoBehaviour {
public GameObject loadingImage;
public void LoadScene(int level)
{
loadingImage.SetActive(true);
Application.LoadLevel(level);
}
}