well at first this might seem like a dumb question, but i really cant find out why this isn’t working
GUILayout.BeginArea(new Rect(Screen.width / 2.5f, Screen.height / 5, Screen.width - Screen.width / 4, Screen.height - Screen.height / 5));
GUILayout.BeginHorizontal();
if (GUILayout.Button("Team1", Style))
{
Debug.Log("I Dont work :(");
GameObject.Find(PlayerPrefs.GetString("Name")).transform.FindChild ("PlayerNameLobby").tag = "RedTeam";
}
/*foreach (string PlayerNames in NameList)
{
GUILayout.Label (PlayerNames, Style);
}*/
if (GUILayout.Button("Team2", Style))
{
Debug.Log("I Dont work :(");
//GameObject.Find(PlayerPrefs.GetString("Name")).transform.FindChild ("PlayerNameLobby").tag = "BlueTeam";
}
/*GUILayout.Space (Screen.height / 25);
foreach (string PlayerNames in NameList)
{
GUILayout.Label (PlayerNames, Style);
}*/
GUILayout.EndHorizontal();
GUILayout.EndArea();
The button created is located at the right spot, its pressable but it just doesn’t give me the log command or any other sign of it working. Its not because of the style since i also tried it without the style.