Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

Pyros-AtEarth

MMORPG MULTIUSER DESIGN

This topic is 5234 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hey there, i have a small game team which we plan on creating a game. The only issue i have is that i am not sure how i can have multiple users. Do other people who use servers use winsock? or directx play? or something else? And how do they handle more than 1 user. Examples would be helpful, as well as meaningful descriptions about them. Thanks alot Pyros

Share this post


Link to post
Share on other sites
Advertisement
There are several different ways to go here in handling multiple users.

1) Spawn a thread for each new person that connects. Basically each connection has their own ''bit'' of time on the server.

Pros: Each person is handled in their own space. Can handle two people at the ''same'' time.
Cons: Big overhead, spreading data across different threads is very difficult to do and do correctly.

2) Deal with data as it comes in. So you see what socket has data on it an deal with it as it comes in and handle it sequentially. Your server maps what user is connected to what port.

Pros: Much easier to handle all data in single thread.
Cons: Could cause latenecy on the server if you process things in order.

3) Worker threads. You set up a few threads to deal with incomming traffic. When a new connection is made it is added to the thread doing the least.

Pros: Can make server more responsive.
Cons: Again, handling cross thread data can be a big pain.





-------
Andrew
PlaneShift - A MMORPG in development.

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!