2nd player is not showing in my screen and I'm also not visible in his screen while testing the game

Options

using System.Collections;

using System.Collections.Generic;

using UnityEngine;

using UnityEngine.UI;

using Photon.Pun;

using Photon.Realtime;


public class CreateAndJoinRoom : MonoBehaviourPunCallbacks

{

  public void Start()

  {

    PhotonNetwork.AutomaticallySyncScene = true;

  }

  public InputField CreateeRoom;

  public InputField JoinnRoom;


  public void CreateRoom()

  {

    PhotonNetwork.CreateRoom(CreateeRoom.text);

    Debug.Log("Room Created");

  }


  public void JoinRoom()

  {

    PhotonNetwork.JoinRoom(JoinnRoom.text);

    Debug.Log("Joinned Room");

  }


  public override void OnJoinedRoom()

  {

    PhotonNetwork.LoadLevel("Level");

    Debug.Log("Loded level");

  }

}


This is my code for joining and creating room.




using System.Collections;

using System.Collections.Generic;

using UnityEngine;

using Photon.Pun;

using Photon.Realtime;

using System.IO;


public class GameSetUp : MonoBehaviour

{

  public GameObject PlayerPrefab;


  private void Start()

  {

    CreatePlayer();

  }


  private void CreatePlayer()

  {

    PhotonNetwork.Instantiate(PlayerPrefab.name, Vector3.zero, Quaternion.identity);

  }

}


This is the code for character game set up.


Im very new to photon. please tell me what I'm doing wrong.

Answers