Hi, I’m new to Unity and I’m doing my school project in Unity, but I don’t know anything.
I’ve been watching tutorials of the things I’m making and at this point I have a problem, I want to change the scene by clicking a button, I have the button with an image and all the options.
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;
public class Cambio : MonoBehaviour
{
public void LoadScene (string sceneName)
{
SceneManager.LoadScene(sceneName);
}
}
I’ve followed the tutorial of the script and everything ok but then when I put the game object with the script in the button, I have only 3 functions: GameObject, Transform and Change. But in the tutorial, the person has the function: ChangeSceneWithButton with LoadScene (string) on it, I have followed all the steps correctly but I don’t know where the problem is.
My Unity version is Unity 2020.3.1f1
If you can help I thank you a lot, I’m very stuck at this point and have been searching for solutions for more than an hour. ^^
Here are some photos of the options and the GameObject I’ve used, the script inside the game object is the one I’ve texted about. Thanks.


The console is completely clean, I don't know why this can happen. [183568-screenshot-7.jpg|183568]
– galyconoficial