NullReferenceExeption Error: Object reference not set to an instance of an object

Hello,

I am struggling to find a solution to this error i receive for my WorldInteraction.Update() script:

void Update ()
    {
        if (Input.GetMouseButtonDown (0) && !UnityEngine.EventSystems.EventSystem.current.IsPointerOverGameObject())
            GetInteraction();
    }

If anyone could point me in the right direction and explain how I am getting this error as I am quite new to programming in Unity would be most appreciated!:slight_smile:

Do you have an EventSystem in your scene?

Ah just added one and it works, thought I had already added one at the time. Silly mistake
Thank you!