I'm looking at using UDP someday to facilitate online play for a simple 3d game. I'd like to be able to get a single-player version running first. Can anyone recommend strategies for making the implementaiton of networking easier? I.e. is there a certain way I should be writing my single-player code now so that I won't hit a wall when it's time to make the game multiplayer?
Network someday, what now?
Started by jcb, Apr 17 2006 12:35 AM
5 replies to this topic
#1
Posted 17 April 2006 - 12:35 AM
#2
Posted 17 April 2006 - 10:37 AM
Implement it like a client-server architecture, even for single player modes. This does not neccesarily mean you need to use sockets co communicate locally, but rather to separate the client (rendering, input) from the server (simulation, AI, ...).
This is a good thing anyway, so there's really no drawbacks.
This is a good thing anyway, so there's really no drawbacks.
#3
Posted 17 April 2006 - 10:42 AM
First of all, don't read the devmaster wiki, since the network section contains some wrongful statements (someone that have some better writings skills than me should correct it). I guess you should probably think about what type of network topology you'd like (server-client, peer-to-peer etc.). If you choose a server-client approach, create 'virtual' network for the single-player by having a server class updating a client class (this is a common approach, see f.ex. the quake source codes). In a peer-to-peer approach my guess would be that you would be able to solve any problems as long as you're able to traverse the scene graph(?)
#4
Posted 17 April 2006 - 10:43 AM
Oh, geon beat me. I'm a really slow typer...
#5
Posted 17 April 2006 - 05:25 PM
SigKILL said:
First of all, don't read the devmaster wiki, since the network section contains some wrongful statements (someone that have some better writings skills than me should correct it).
What part are you referring to exactly?
I couldn't find a networking specific part on a quick peruse, and I'm in a Wikification type o' mood. I could spruce it up.
#6
Posted 18 April 2006 - 07:29 AM
It isn't too bad, but http://www.devmaster...wiki/UDP_vs_TCP is both badly written, and contains some errors in the UDP section. The UDP uses CRC to verify the content of recived packets.
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users











