Jump to content
Eternal Lands Official Forums
Sign in to follow this  

MMORPG programming ..

Recommended Posts

Hi everyone!

We are trying to develop an online multiplayer rpg, so i thought that maybe someone of the EL creators (but anyone else would be good of course) could give me some advice :P


Which is the best language for this purpose (according to you) ?

What could i use to get the client-server protocol working easily ? (i'm a bit scared of the multithread approach in C..)

Which are your favourite gfx libraries? (i'd like to create something light.. i prefer to privilege gameplay instead of gfx)


I know that there are many solutions, so i'd like to know the "strategies" you would use for this job :icon13:

Hope that someone have time/desire to answer my question, and maybe this post could interest some other user.


Thank you all!


PS: Please, have mercy for my bad english ... :goofy:

Share this post

Link to post
Share on other sites

Unreal Engine and SDL2.


SDL is a multi-platform abstraction layer over OS multimedia and input capabilities (and networking as well). SDL2 has wayland support so a more viable choice on the long run if you wish to support Linux since x11 will eventually start to fade away. An alternative to SDL is SFML.


But you will need a full 3d engine either way. Among the popular ones are Unreal Engine, Unity 3d, and Allegro.

Share this post

Link to post
Share on other sites

First of all, i wanna thank you guys for suppporting me :wub:

Just some additonal question:


- Using SDL, do i find some function in that library which simplify use of (p)threads, or instead SDL give support only for networking (ex: handling sockets)?

- Do you know some tutorial (for C(++ / #) and SDL) which gives some guidelines to server-client implementation for generic online multiplayer?


I'm pretty sure there's something i didn't get, for example about multithreads.. do i have to implement something like "mutex", to access shared vars?


Well.. so many things to learn.. and a strategy to choose.. :P

Share this post

Link to post
Share on other sites

This is going to be a bit rambling, as there are a lot of things involved :)


- Don't forget you are dealing with two different systems: the client and the server. These don't have the same requirements, and don't have to be written in the same language. The only link between them is your communications protocol, which should be language-independent.


Server-side, you won't have much graphics programming going on, but you'll have to deal with a lot more data, and speed might be an issue. That means multi-threading is probably needed (but perhaps not in a first version).


Client-side, speed shouldn't really be a problem, and you deal with a lot less data, but you sure will have to do graphics programming. But you might be able to avoid multithreading completely (depending on how fancy you want to get with your client), making the code a lot simpler.


- If you are planning on using C++, do make sure to use the latest standard: it has (some) support for multi-threading (threads, mutexes, atomics, etc.), and memory handling has also become a lot easier with the different smart pointers. At least one compiler (GCC) has most of those features implemented.


Personally, I prefer using language features over external libraries: a standard language feature should be supported on all platforms for which there's a conforming compiler, libraries are not necessarily ported to all those platforms.


- For the networking part, have a look at the Boost libraries as well: there are rumours the async part of boost might end up as a C++ standard library (wouldn't be the first time a Boost library ends up as part of the standard).


- C# and the other .NET languages are poorly (if at all) supported under Linux; I don't know if they are supported under MacOS. Perhaps not a problem for your server, might be more important for the client.


- Concerning the advise not to use Java: I have to disagree, at least for the client side: within the 'standard' language you have multithread support and at least two GUI toolkits. And for the client, it should be fast enough. It even has some graphics libraries available (no idea how good those are).


- Unless you already know C pretty well, it would not be my language of choice: not much you can do in C that you can't do in C++, and the data structures in C++, coupled with the algorithm library and smart pointers make life a lot easier.

Share this post

Link to post
Share on other sites

Well.. implementation started in C++ (for both client and server)


1) For now, we are using SDL to make a simple 2d client (just for testing.. we will probably switch to OpenGL).

2) For the networking part, we found this: http://vichargrave.com/multithreaded-work-queue-based-server-2/

it's a nice set of objects/methods for producer-consumer model, queue based (they implement mutex inside, so they are really handy).

3) For client/server message protocol, we wanted to use JSON "format".


When we'll finish networking.. the rest it's a matter of design :ph34r:



Ohh.. and we need to choose an efficient db ...



Just started studying noSQL databases, in particular MongoDB ... this should be a good compromise between perfomance and convenience.


Edited by marmz

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.