Hi,
I am not able to see the Level in Debug mode (for the Hacker script at the right side).
Even I ran the game, it is not showing the level.
I am using unity 2019.1.0a14 version.
You can find the codes and the ss of the unity below.
Could you please help me to find what is wrong?
using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class Hacker : MonoBehaviour
{
//Game state
int level;
// Start is called before the first frame update
void Start()
{
ShowMainMenu("Hello Yigit");
}
void ShowMainMenu(string greeting)
{
Terminal.ClearScreen();
Terminal.WriteLine(greeting);
Terminal.WriteLine("What would you like to hack into?");
Terminal.WriteLine("Press 1 for the local library");
Terminal.WriteLine("Press 2 for the police station");
Terminal.WriteLine("Enter your selection:");
}
void OnUserInput(string input)
{
//print(input == "1");
if (input == "menu")
{
ShowMainMenu("Hello again Yigit");
}
else if (input == "1")
{
level = 1;
StartGame();
}
else if (input == "2")
{
level = 2;
StartGame();
}
else if (input == "3")
{
level = 3;
StartGame();
}
else
{
Terminal.WriteLine("please choose a valid level");
}
}
void StartGame()
{
Terminal.WriteLine("You have chosen level " + level);
}
}