Page 1 of 1

getRoomList() after room joined

Posted: 09 Jun 2008, 13:48
by baczy
there seems to be a problem when calling getRoomList() after the user joined a room. example:

#1 = client 1
#2 = client 2

#1 joins lobby room. myLobbyRoom.userList contains player #1.
#2 joins lobby room. myLobbyRoom.userList contains player #1 + #2.
#1 onUserCountChange received: room.getUserCount()=2 and myLobbyRoom.userList contains player #1 + #2

so far, so good. now the same thing when each client calls getRoomList() after joining the lobby room.

#1 joins lobby room. myLobbyRoom.userList contains player #1.
#1 invoke getRoomList();
#1 onRoomListUpdate received
#2 joins lobby room. myLobbyRoom.userList contains player #1 + #2.
#1 onUserCountChange received: myLobbyRoom.getUserCount() reports 2, but myLobbyRoom.userList contains only player #2, player #1 is undefined!
#2 invoke getRoomList();
#2 onRoomListUpdate received

Posted: 10 Jun 2008, 13:53
by Elo
Hello baczy,

i have the same problem. The only solution i found is first to call the getRoomList method and on the event onRoomListUpdate to join the Lobby.

It is quite dirty to do it this way, but i found no other solution.



Greetings,

Marc