So überprüfen Sie die Szeneneinheit

Use SceneManager.GetActiveScene(); to get a string with the scene name

Note: You have to write using UnityEngine.SceneManagement in the top
Alex_Chipmunk