I am very new to coding and I am currently following this tutorial:
The errors I am having are:
This is my code:
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using Photon.Pun;
using Photon.Realtime;
using UnityEngine.UI;
public class MenuController : MonoBehaviour
{
[SerializeField] private string VersioName = “0.1”;
[SerializeField] private GameObject UsernameMenu;
[SerializeField] private GameObject ConnectPanel;
[SerializeField] private TMPro.TMP_InputField UsernameInput;
[SerializeField] private TMPro.TMP_InputField CreateGameInput;
[SerializeField] private TMPro.TMP_InputField JoinGameInput;
[SerializeField] private GameObject StartButton;
private void Awake()
{
PhotonNetwork.ConnectUsingSettings();
}
private void OnConnectedToMaster()
{
PhotonNetwork.JoinLobby(TypedLobby.Default);
Debug.Log(“Connected”);
}
public void ChangeUsernameInput()
{
if (UsernameInput.text.Length >= 3)
{
StartButton.SetActive(true);
}
else
{
StartButton.SetActive(false);
}
}
public void SetUserName()
{
UsernameMenu.SetActive(false);
PhotonNetwork.playerName = UsernameInput.text;
}
public void CreateGame()
{
PhotonNetwork.CreateRoom(CreateGameInput.text, new RoomOptions() { maxPlayers = 3 }, null);
}
}