online multiplayer tutorial?
Posted 15 January 2013 - 08:24 PM
there is this strategygame im playing, and i want to make a simulator of one part of the game, to train working together with others,
the issue is that i can make the game easy enough, but dont know how to make a online multiplayer game
i have looked around, and i saw some tutorials, but they are usually very focussed on 1 type of game, and not on making the online part, they usually just give you that.....
Posted 16 January 2013 - 04:18 AM
Just dont go tackle the 100 simultanious players right at the start.
Posted 16 January 2013 - 08:10 AM
Posted 16 January 2013 - 08:53 AM
the game im simulating would be fine with 4 - 6 or 8 players, 2 however would not be enough
Posted 16 January 2013 - 11:44 AM
Once you get the gist of socket programming, you need to learn about asynchronous programming. If you're not up to par with this, you should learn about threads and various thread patterns (task scheduling, thread pooling, event/delegate pattern).
After completing the above, you should start thinking about creating your own protocol, on top of TCP/IP or UDP. By now you should know what those two are and how you should use them. Your games however will need a format of their own, something your code can parse and extract data from. HTTP is an example of a protocol built on top of TCP/IP. Once you define your protocol, you will need to create all the possible packets that can be sent and received for your game, and then build a packet handler to manage that. This is where you will need to think about a good design to put all the pieces together.
Finally, you will have to think about latency and synchronization, network prediction, and protocol compression. I haven't seen these topics covered well, but they are fairly intuitive. At least if you get as far as doing all of the above, you should be able to problem solve these as you go. As you get more experience, these solutions will come more naturally to you.
Posted 16 January 2013 - 12:09 PM
then i have some work to do XD
i figured this game i was planning would be easy compared to a normal game, as the computer only have to send information 1 time in 30 seconds to tell the moves that are made, as it is a turn based strategy game in which the turns are done at the same time, so the players have 30 seconds to guess what the others will do and put their own moves ready, and then the server asks for the moves and calculates what happens.
Posted 16 January 2013 - 06:28 PM
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users