How to display photon private rooms on rooms list

Options
Hi,
if this question exist or not But i have not found the solution for this.
if exist sorry for that.
I have an doubt about photon room creations.
I told to you what iam doing.
In my game player can play two types of rooms. In one type room player is playing with players but everything is running through AI. In second room players can play with each other But some functionalities are different compare to first room.If he need to play on second type room he need to pay coins.But in first type room player can play with out paying coins.
When iam creating first type rooms at that time i am doing join random room.player can join random rooms and create also(if room not exist).But now i need to differentiate second type rooms,Only who have more coins(for ex:10L coins) he only can create room but any one can join to the room. __Now i need to work here__.I need to show only second type rooms list that can't be Join randomly other players(I.e first room persons can't join to second room.Who the person is selected to join second type rooms he can only join).__Now how i create the room .Please guide me__ .Here room created person is the master.If he lefts game has to be close.But in 1st type rooms master is left it is shifting to next person.
Sorry for my English.
Thanks in advance.

Comments

  • JohnTube
    JohnTube ✭✭✭✭✭
    Options
    Hi @YantramStudios,

    Thank you for choosing Photon!

    To make difference between rooms you can:
    - create rooms in different lobbies (e.g. "free lobby", "paid lobby").
    - make rooms with lobby properties (e.g. "required coins").

    Here room created person is the master.If he lefts game has to be close.But in 1st type rooms master is left it is shifting to next person.

    This is done for you in Photon Realtime/PUN. See here.
  • Hello,
    Thanks for your Quick response.

    This is done for you in Photon Realtime/PUN. See here.
    This one i have done previously.But i have mentioned to get a clear idea to the users.

    - make rooms with lobby properties (e.g. "required coins").

    here who the creating user,that user only need coins to create it.But any one can join.
    Is there a possible way.
    Please guide me.
    Thanks.
  • JohnTube
    JohnTube ✭✭✭✭✭
    Options
    Here is how I see it:

    call join random or join to the rooms inside that lobby.
    if none is found, check if player can create (have coins) and then create the room and reduce/consume/decrement the amount of coins necessary.

    if you need to protect your game, you should implement webhooks and have your own web service or a third party one (PlayFab for instance). This way you can make sure that no room is created without the player having enough coins and you can even reduce/consume/decrement the coins from server side.
  • I give a little explanation what i am doing.
    here are two buttons-
    1st button if we press we can join multiplayer mode. iam doing here 1st randomroomjoin if room not exist creating new room(he is a master).if he lefts next person is the master.No limitations for joining and no rules.
    Now 2nd button if i press i need 10L coins min. to create room.If not have we can't create room.Now we created room (here i need to show that room to users who clicked 2nd button.If any one interest to join he can join.No need of min. coins.Here master is left, the match will be close).Here i am calling the user to lobby and displaying rooms.But 1st button rooms also displaying.When i false the room visibilty for 2nd button it is not showing in the list.
    Thanks.
  • JohnTube
    JohnTube ✭✭✭✭✭
    Options
    if you want to list all rooms to join at once paid and free then use a single lobby and use a lobby property to make a difference between paid and free.
    for paid rooms, when master leaves, force all players to leave.
  • Sorry!
    Here i need to show only 2nd button rooms,no need to show 1st button rooms.
    If i use only one lobby then 1st button room having different functionality and 2nd button room having different functionality.
  • i am made the card game with multiplayer.
    In 1st button room player win or loose coins are giving through CPU.(for ex: player won cpu gives 100 coins,if he loose cpu deduct 100 coins from their account.).But in second button room who having 10L coins he can only create room but any one can join.here another player joined the room he bid the amount and he won the game.now i am deducting the amount from the master and adding to the user.If user loose the match that coins directly add to the Master.
    Here i need to work.
    In 1st button room are joining random room.But if you need to join 2nd button room .here you can select rooms and join.(if you have a enough coins you can create your own room and user can join to your room).
    1st button room functionality is different and 2nd button room functionality are different.
    Now i need here 1st btn room users can't join to 2nd button rooms.But i need to show 2nd button rooms list only.
    If you get any confusion with my English please tell me.
    Thanks.
  • JohnTube
    JohnTube ✭✭✭✭✭
    Options
    First button (free game vs. CPU where you win or lose coins): join random room from lobby A or create new one if none is found inside lobby A. If it's against the CPU than you can even skip Photon altogether! Or even create rooms invisible and Lobby A = Lobby B.
    Second button: (paid game pvp): show list of rooms from lobby B. if player has enough coins and wants to create a new room, create it inside lobby B.
  • hi,
    Thanks for your reply.
    Before this you have told that create custom rooms.
    yesterday I have implemented the custom rooms with custom property.This is now working fine.
    Thanks.