Forum Multiplayer Room persistance?

Discussion and help relating to the PlayerIO Multiplayer API.

Room persistance?

Postby tfernando » January 24th, 2010, 9:08 pm

How long do unused rooms (roomInfo.onlineUsers == 0) persist? (Ie: How long timewise after I call client.multiplayer.createRoom can I assume the room still exists?)
tfernando
 
Posts: 2
Joined: January 23rd, 2010, 6:26 am
Location: Anchorage, AK

Re: Room persistance?

Postby Oliver » January 24th, 2010, 9:23 pm

In general, the rule is very simple.

- When the last person leaves a room, it closes.
- We don't close a room until it's existed for some amount of time with no players; a few minutes (can't remember the specifics right now, i'm at home...).

A time out mechanism is implemented for the last case. However, we've noticed this week that there are a few edge cases that we'll fix during the next week, and that the default timeout (4-hours) for development rooms is *Waaaay* too long.

So, to answer your question: Rooms are supposed to only be there when there are people in them. When you call createRoom, you can reasonably expect the rooms to be there for a few minutes.
User avatar
Oliver
.IO
 
Posts: 1159
Joined: January 12th, 2010, 8:29 am

Re: Room persistance?

Postby Cyclone103 » January 25th, 2010, 4:19 pm

If your goal is to persist rooms, you can use createJoinGame to join/create the room when needed. You can manually add rooms to the example lobby fairly easily.
Cyclone103
 
Posts: 155
Joined: January 18th, 2010, 6:47 pm


Return to Multiplayer



cron