Heloo Guys II have problem with my Menu Script it says : Assets/Scripts/MenuManager.cs(47,33): error CS1502: The best overloaded method match for `UnityEngine.GUI.TextField(UnityEngine.Rect, string)’ has some invalid arguments
When i start game it shoud apear my buttons or. Menu for FPS game and it dosent show anythyning. Here’s Code
CurrentMenu = "Main";
}
void OnGUI()
{
if(CurrentMenu == "Main")
Menu_Main();
if(CurrentMenu == "Lobby")
Menu_Lobby();
if(CurrentMenu == "Host")
Menu_HostGame();
}
public void NavigateTo(string nextmenu)
{
CurrentMenu = nextmenu;
}
private void Menu_Main()
{
GUI.Button(new Rect(10,60,200, 50), "Host Game");
{
NavigateTo("Host");
}
}
private void Menu_HostGame()
{
//Buttons Host Game
if(GUI.Button(new Rect(10, 10, 200, 50), "Back"))
{
NavigateTo("Main");
}
if(GUI.Button(new Rect(10, 60, 200, 50), "Start Server"))
{
}
GUI.Label(new Rect(220, 10, 130, 30), "Match Name");
MatchName = GUI.TextField(new Rect(400, 10, 200, 30), MatchName);
}
private void Menu_Lobby()
{
}
}