I am trying to code a button to change the scene but I keep getting:
Assets\SceneChange.cs(6,42): error CS1031: Type expected
How can I fix this? (I am very new to coding)
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;
public class SceneChange : MonoBehaviour,
{
public void MoveToScene(int sceneId)
{
SceneManager.LoadScene(Career, Menu);
}
}
Assets\NewBehaviourScript1.cs(4,19): error CS0234: The type or namespace name ‘SceneManagment’ does not exist in the namespace ‘UnityEngine’ (are you missing an assembly reference?) happens
Assets\NewBehaviourScript1.cs(4,19): error CS0234: The type or namespace name ‘SceneManagment’ does not exist in the namespace ‘UnityEngine’ (are you missing an assembly reference?) happens
Probably because you have incorrectly spelled SceneManagement. It is not SceneMangment, which is what you have typed.
You have to be 100% accurate with what you are typing, and should not need to come to the forum to fix up your typos.