PhotonNetwork.CreateGame()

Options
Anyone can tell me, How to create game with ActorProperties? I tried to use this method,
PhotonNetwork.networkingPeer.OpCreateGame(roomName, isVisible, isOpen, (byte)maxPlayers, PhotonNetwork.autoCleanUpPlayerObjects, customRoomProperties,actorProps, propsToListInLobby);

but, when i come into room, PhotonNetwork.player.allProperties has only one key, (255) playerName.
I tried to use PhotonNetwork.player.SetCustomProperties() this method works, but only inside the room. How to send ActorProtperties when Joining or creating Room?

Comments

  • Tobias
    Options
    Good point. We didn't expose the actorProperties in JoinRoom, JoinRandomRoom and CreateRoom. Missed that.

    I was about to add this and when I was done with CreateRoom, it felt like adding spam to the API.

    So, I think the best way to support this is by setting them through a setter method in PhotonNetwork. It will check if you are in a room or not, cache and only sync them if possible. They will be set on join OR create, which is most likely what you need.

    We will update PUN asap, due to a known issue, so look out for the update beyond 1.10.