Queuing?

Started by
2 comments, last by MatsVed 13 years, 4 months ago
This is kind of a general question, but;

How do you design and implement a queue system like in WoW, where if a realm has, say, > 3000 players, you are put in a queue and the number of players that are in the queue are kept track of for you until you can play?
Advertisement
just append the players to a list,and when a spot is open on server then move the person indexed at [0] to the list of connected players. it would be a feww while,for, and if loops in python but I'm not sure what language you're using. And if this is a solution you're having trouble implementing then maybe(most likely) an mmorpg wouldn't be the best choice.
One fairly trivial way, given the usual infrastructure would be to create a "QueueWorld". When selecting which shard/realm/node to connect to, if cluster is full, everyone is put into QueueWorld. It can also serve as default login/front-end.

QueueWorld is just regular world server, but it does not have any 3D representation, and users cannot perform any commands, thereby avoiding the congestion issues. Only the socket part needs to scale, but this shouldn't be an issue.

The in-world script then polls availability on real world, and every 10 seconds or so selects who to transfer.

The advantage here is very high-level implementation. Since cluster will need to support migration, authentication, load balancing and reporting, user tracking, scripting, ... it makes sense to use all these facilities at highest possible level.
Makes perfect sense, thanks! :)

This topic is closed to new replies.

Advertisement