-1
\$\begingroup\$

I am building an asynchronous multiplayer game (which can be compared whith a chess game) with Unity (up to 4 players in game). But I am stuck at choosing the server side solution.
For me this kind of game, asynchronousby and I also mean no realtime updating, can be handled by only http requests and a database (to maintain a game for example).
All connections to the database are made on the server side of course, not on the client.

What's the difference between a socket server and a http server according to my project. A simple Http server could handle any action and link to the database but it seems to be slower.

I saw that using RPC calls might be better.

Thanks a lot for your help and advices.

\$\endgroup\$
4
  • \$\begingroup\$ Exposing a database to the clients directly is a very short-sighted approach. Remember that players need to be prevented from cheating. This means that all data which is sent to the server must be validated for being in accordance with the game rules. In order to do that you will have to implement considerable logic on the server. \$\endgroup\$
    – Philipp
    Commented Apr 2, 2013 at 15:50
  • 2
    \$\begingroup\$ "Which tech to use" questions are off topic for the site. See the faq. \$\endgroup\$
    – Tetrad
    Commented Apr 2, 2013 at 16:29
  • \$\begingroup\$ I edited my question, I think I misspoke that's why you miss understood my question. \$\endgroup\$
    – MaT
    Commented Apr 3, 2013 at 7:25
  • \$\begingroup\$ Your question "What's the difference between a socket server and a http server according to my project?" isn't really related to game dev and pretty localized since it's limited to your project. You should consider expanding it and asking it on stackoverflow. \$\endgroup\$
    – House
    Commented Apr 4, 2013 at 22:30

1 Answer 1

1
\$\begingroup\$

The client should almost always be ignorant of the database. And if it does know about the database, expect security issues.

As for choosing a server, you do not need a brand name server. You can build your own socket server in any platform under any language you like. You'll need a socket library to extend Unity's functionality unless you have access to Pro. Other than that it's all yours.

\$\endgroup\$
1
  • \$\begingroup\$ Of course the client is ignorant of the database, all link with the database are on the server side. I have Unity Pro, but I don't get the point of building a socket server for an asynchronous game, by asynchronous I also mean no realtime updating. \$\endgroup\$
    – MaT
    Commented Apr 3, 2013 at 7:32

Not the answer you're looking for? Browse other questions tagged .