Can GameNet support hundreds of players?

BlitzMax Forums/BlitzMax Beginners Area/Can GameNet support hundreds of players?

Apollonius(Posted 2007) [#1]
Well I've been wondering about alot of things. How powerful is the GameNet Modules? Could it support hundreds of players on a dedicated machine? Sockets seem quite complicated... And Raknet? There's no real Wrapper or Tutorial to use it with BlitzMax...

I've been trying to make a simple RPG/Chat Room but I want it to be able to supports around 200+ Players on a dedicated 100MBPS Server.

What are your thoughts? Is it doable with GameNet?

Final Stage I'd love to add in SQL support for data management and I know this is possible. But my main problem is finding good and simple multiplayer that I can work with. Since there's no real tutorial.

EDITED
I just found a raknet bmax wrapper
http://repeatuntil.online.fr/raknet/index.html
example didn't work for me saddly.


Dreamora(Posted 2007) [#2]
If not all players are on the same host, it can work yes.
If you mean for MMO or the like: no never. You need a highly specialized networking to handle more than a few dozen players in a single environment.


Apollonius(Posted 2007) [#3]
So my best chance for a mmo would be sockets? TCP or UDP?


RepeatUntil(Posted 2007) [#4]
Apollonius, please tell me why the RakNet examples did not work? If you report what you did/didn't see more precisely, I may be able to correct whatever have to be corrected. The examples were working for a lot of people, so I am a bit surprised.


Dreamora(Posted 2007) [#5]
For MMO you will need to use an UDP based network and implement yourself a very efficient packet structure (as less information as possible) potentially with compression.

That and an intelligent ghosting / syncing handling to prevent all data beeing sent to all users, which will not work with more than 50-100 players at best.


FlameDuck(Posted 2007) [#6]
Could it support hundreds of players on a dedicated machine?
No.

Is it doable with GameNet?
No.

So my best chance for a mmo would be sockets?
Your best bet for an MMO is to hire someone who's written more than 2 MMO backends. writing a decent MMO network framework, that scales well is an NP complete problem (one that cannot be solved ideally in polynomial time), and thus one of the most difficult problems facing traditional computer sciences. Generally people who write MMO's solve this problem by throwing ridiculous amounts of processing power into the equation, but due to BlitzMAX lacking a good threading model (or for that matter A threading model), your only real option is a scientific breakthrough. Alternatively you could try writting it in Erlang.


Apollonius(Posted 2007) [#7]
damn so it's not possible to make a simple 2D MMORPG at all? /sob, my 7 years dream down the drain... I wana make a 2D MMO :(


FlameDuck(Posted 2007) [#8]
damn so it's not possible to make a simple 2D MMORPG at all?
Sure. But it's a fairly daunting task. I don't know you, so for all I know you could be a rocket scientist, and making a 2D MMO is something you could do in your sleep.

An MMO is a complex beast, often taking large teams of developers several years to complete. Writing the network framework to support the transfer of those enormous amounts of data efficiently is a nontrivial task.

But hey, don't let some total stranger on the Internet discourage you of your dream. While it may not be immediately feasible in BlitzMAX, or on simple hardware, you can write it in another language (like 3Rings did with PuzzlePirates) or scale down your initial player target, hope that multithreading makes it into BlitzMAX sooner rather than later. Also if you plan to make it scalable, outgoing network traffic is only half of your worries - you're going to want to have separate physical computers talking to each other internally - again a nontrivial task.

Maybe start off with a MUD or simple multiplayer game - at least that way you'll learn how to deal with the different degrees of complexity inherent to this kind of software.


Czar Flavius(Posted 2007) [#9]
I agree. Make a fully-working "smallscale" mutliplayer RPG first, then think about MMO.


Apollonius(Posted 2007) [#10]
if i utilised c++ with raknet, would it be achievable.


marksibly(Posted 2007) [#11]
Hi,

If it's not 'realtime' - eg: a chat or turn based thing - then yes.

Otherwise - eg: if you need to send stuff in realtime - then no.


FlameDuck(Posted 2007) [#12]
if i utilised c++ with raknet, would it be achievable.
Honestly? If you can't make it work in BlitzMAX, you won't stand a chance with C++.


Apollonius(Posted 2007) [#13]
Well after looking around for awhile, asking lots of questions, it seems to be as c++ and raknet working togheter would be possible although I would need to get extremely familiar with how server and client interact using the c++ language and Raknet. Then I would simply need to get one of those billion 2D API out there to make my job somewhat easier.

Basicly to me the game I wana make would be quite simple. Have you ever played Zelda on Super Nintendo? Well my idea is somewhat as simple as that game was.

X and Y Coordination on a tile map. So that would be general player coordinations. Managing that at first... Then creating a piece of code that would only send informations about the players that are close to you only aka on the screen or a certain number of step away.

I mean, if won't be that easy but I think with all the help I can get from the Raknet forums and my friends from the c++ world(aka also my past experience with c++) I certain think a could achieve something that could probably hold up a hundred players.

A very dedicated server would surely be able to handle such a small task as handling a hundred player coordination and then sending all the coordination to those within range of eachother. Anyway... Thanks for the blunt honesty, but my simple dream flies higher, I won't be defeated soo easily after 7 years, I ain't quiting now teehee~!

Have a good day everyone! :)
Gimme a BMAX SDK Mark~


Dreamora(Posted 2007) [#14]
Just to make it simpler: there are different 2D MMO creation kits. Freely available on the net.

Perhaps using one of those might give you more than trying to get it done on your own.

Even doing the networking side of an MMO is something that only few (on earth) are able to achieve as it isn't something that can be clearly specified. Its complexity is that high that you can not design it for any case nor can you test it in any ... so you will need to be willing to do a lot of testing and modification etc.


FlameDuck(Posted 2007) [#15]
it seems to be as c++ and raknet working togheter would be possible
It's not a matter of what's possible. It's a matter of what's practical. You can drive a car with your feet if you want to, that doesn't mean it's a good idea.

although I would need to get extremely familiar with how server and client interact using the c++ language and Raknet.
That's the easy part. The difficult part is figuring out how to effectively manage the network traffic.

Then creating a piece of code that would only send informations about the players that are close to you only aka on the screen or a certain number of step away.
Well done. This is part of the problem. Unfortunately it's a fairly complex problem. It works reasonably well for small numbers of clients (like 30 - were you only have to do 465 distance calculations), but but grows exponentially as the number of clients grow.

Why? Because for each (n) extra person you add, you need to check (n-1) distances to other players.

A very dedicated server would surely be able to handle such a small task as handling a hundred player coordination and then sending all the coordination to those within range of eachother.
The task is a lot more complex than you think, and using a less abstract language (like say c++) is not going to do you any favors regarding managing complexity.

Not considering the potential memory management hell, creating a dense graph of 100 nodes in C++ would be, you would need to do at least 5050 distance calculations each time you want to send out data.


Apollonius(Posted 2007) [#16]
Saddly you guys are quite right after looking around and trying things. There is just no way I could code the network side of the MMO-RPG. And even with raknet, which I can't get to work with Dev-C++, it would take me a long time to figure out how to fully utilise it's full potential. I was planing to use:

HGE 2D Engine with Raknet, I got the HGE engine to work quite well but I failed into being able to install Raknet with it.

Then tehre was this second option which is
SDL with the SDL_NET Library which is said to be fairly easily to use(SDL_NET) and after seeing the TCP commands, it seems fairly easy but I shouldn't fool myself nothing is ease when it comes to networking. However I havent tested this yet. But from what I heared it's hard to install SDL with DEV who knows..

My 3rd option would be a MMORPG engine which isn't easy to find for the job I wana do. Plus, I havent found any 2D MMORPG Engine. There's only a billion 3D MMORPG Engine like Realm Crafter that is made with Blitz3D.

Oh another note, I was told it's possible and easier for newbies to use the TCP Protocol to make a MMORPG then the UDP...

So hopefully I can figure something out... Another question, would it be possible to make the server in C++ and make the client with BlitzMax, I'd say yes because it would be a matter of communication through TCP sockets..

If I did that then the idea with blitzmax is doable. Just not server wise.


FlameDuck(Posted 2007) [#17]
I was told it's possible and easier for newbies to use the TCP Protocol to make a MMORPG then the UDP...
I'm sorry, but whoever told you that is wrong. The TCP overhead is going to absolutely kill an MMO.

Another question, would it be possible to make the server in C++ and make the client with BlitzMax, I'd say yes because it would be a matter of communication through TCP sockets.
Sure. But it would be better to use BlitzMAX for both. There are several reasons for this, but the main one is not having to maintain two different versions of the network code.

If I did that then the idea with blitzmax is doable.
I think the best approach here is to start small (much smaller than you're currently thinking), and scale up. If you intend to write a "true" MMO then you're going to need more than one physical computer as server anyhow - so regardless of language you need to come up with a distributed network protocol.

It also depends on what kind of MMO you want to do. Something like Guildwars is simpler than something like Puzzle Pirates, which is simpler than World Of Warcraft, which again is simpler than something like EVE. You need to start out by planning out how you're going to deal with the network handling, and dispatching traffic to players. Once your preliminary design is ready, implementing is it probably easier than you thought, no matter which language you chose to use.

If you then find out something isn't quite working, go back to your design and try and see if you can fix it there first.


Czar Flavius(Posted 2007) [#18]
Have you considered where are you going to find people to test and play your MMORPG? It's difficult to get 100 people on something at exactly the same time for a significant length of time, especially if your game is incomplete or trivial.


Apollonius(Posted 2007) [#19]
My game design would be abit different then click/attack click/move... This has been doen over and over and over.

Basicly my design plan is, real time movement using arrows keys... and buttons to do attacks aka Zelda SNES and aka children of mana.

Server would keep track of
Player n Monster.. at first only locations then add in distance calculations... like if a monster is near a player and the player attacks it then the monster would lose health.

So basicly locations, character's sheet and monster's sheet... and then NPC's sheet... I think the server should be able to keep track of those and send information as needed to the clients.

As for the question about beta testers.. that would be the easier part, being part of one very large supportive guild... Which has 200+ players... no problem.


Dreamora(Posted 2007) [#20]
This is not even trivial task with realtime networking unless you have years of experience in MMO network programming.

Did you never ask yourself why there are no MMO with 100% realtime combat :-)


Apollonius(Posted 2007) [#21]
Yeah thats why It's time for revolution! LOL.

But yeah its quite above my knowledge


Bremer(Posted 2007) [#22]
DDO (Dungeons and Dragons Online) has realtime combat, as far as I know. So at least one MMO does have it, but most are like WoW where you click and the character fights on his own. In DDO you have to move and fight yourself constantly.


Czar Flavius(Posted 2007) [#23]
Never played DDO but I'm assuming that the fights take place in some kind of "instance" limited to a few players, isolated from the rest of the world? Would this be correct?


Bremer(Posted 2007) [#24]
the fights take place in some kind of "instance" limited to a few players


Yes that is correct for quests with up to 12 players and from a few to a lot of monsters. Sometimes they have events where monsters comes into the towns, and then its a free for all up to a limit, where it will instance the town, but I have no idea about what that limit is, but its a lot.

As far as programming network solutions to handle this kind of thing, I think its something best left for highly skilled programmers working in a good team. But I am sure that small networked games could be handled, because a number of people have already done so, but its surely not an easy thing to start out with.