Having issue where the scene is not loading. I am on VS studio. Also, I couldn’t get the strings to show up on console with previous switch statement lecture. The following is my code:
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;
public class CollisionHandler : MonoBehaviour
{
void OnCollisionEnter(Collision other)
{
switch (other.gameObject.tag)
{
case “Friendly”:
Debug.Log(“All good. No problemo.”);
break;
case “Finish”:
Debug.Log(“You didn’t suck!”);
break;
case “Fuel”:
Debug.Log(“You’ll probably need this.”);
break;
default:
ReloadLevel();
break;
}
}
As soon as I add the Reload Level portion, I am unable to run the game. All I see is Sandbox not loaded and I can’t control at all. Also, for some reason even after I assign the script to the rocket, I do not get the strings to display on console whenever the rocket collides with anything.