- Home /
This question was
closed Apr 26, 2020 at 01:52 PM by
joshanimations12345 for the following reason:
fixed
Question by
joshanimations12345 · Apr 28, 2020 at 01:40 PM ·
scene-switchingkeypressscene-changescene load
Unity 2019.3.11f1 # Scene isn't changing, neither is the script working.,Unity 2019.3.11f1 | My script isn't executing.
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;
public class TestIt : MonoBehaviour
{
void Start()
{
}
// Update is called once per frame
void Update()
{
if (Input.GetKeyDown("space"))
{
SceneManager.LoadScene("lvl1"); //Loads the second scene called lvl1
}
}
}
I'm using Unity 3D and the script isn't working, I press space, nothing happens.
Comment
Follow this Question
Related Questions
Old scene still appears for short time when switching scene 0 Answers
Switching Scenes Via Button Only Works for One Transition 1 Answer
Is there any ideas to load Unity scene asynchronously? 1 Answer
Most efficient way to transition between scenes? 1 Answer
Unity Scene loading problem (slow loading until it freezes) 0 Answers