Game Networking Logic Resources

Hey,

ive only started doing some networking recently, and am wanting to make a network game, supporting ruffly up to 20 people is my desire.

I was just wondering if anyone could point me in the direction of some good learnign resources for this tpye of stuff, that focuses mainly on the game logic, as ive found fairly good resources, and understand setting up the connections and protocols already. As in, how the server should be structered, handling which aspects of the game, structuring of a common class to store each clients information in the server, ect…

Thanx.

[quote]Hey,

ive only started doing some networking recently, and am wanting to make a network game, supporting ruffly up to 20 people is my desire.

I was just wondering if anyone could point me in the direction of some good learnign resources for this tpye of stuff, that focuses mainly on the game logic, as ive found fairly good resources, and understand setting up the connections and protocols already. As in, how the server should be structered, handling which aspects of the game, structuring of a common class to store each clients information in the server, ect…

Thanx.
[/quote]
You could have a look at:

http://www.grexengine.com/sections/people/adam/nio/Introduction_to_NIO_Networking.html

and let me know what questions that leaves unanswered…

There’s a few more bits I’d like to add, but the three articles are mostly complete; just looking for feedback at the moment. They’re focussed on NIO networking, so assumes some knowledge of old IO, but the aim is to explain NIO well both to people who’ve used old IO, and those who haven’t done any game networking before at all.

If you’ve got any comments, send them to ham.nioguide.adam @ grexengine.com (but remove the spaces first…).

If his limit is 20 players NIO might be over-kill.

I’d suggest starting with java.net which is a lot easier to learn and then branching out to NIo if you really need the performance.

Just IMO.

[quote]If his limit is 20 players NIO might be over-kill.

I’d suggest starting with java.net which is a lot easier to learn and then branching out to NIo if you really need the performance.

Just IMO.
[/quote]
If you haven’t read the articles yet, one of the points I try to make is that IMHO NIO is considerably easier to learn than old IO as your first networking technology.

Like trying to teach Smalltalk as a first programming langauge rather than say Basic - ST is much easier, but only if you’ve never programmed in something like basic / pascal / etc.

Ditto functional languages are extremely hard to get used to for many people who’ve learnt any significant C or C++, but typically much easier for people who’ve done none.

And, other than joining an existing project that uses old IO rather than NIO, I can’t see a situation where knowing NIO but not old IO is going to be a disadvantage.

Just like you were saying with Collections the other day (“Vector is a dead-end technology…not going to be updated in the future” IIRC?) - NIO is the future path for all I/O in Java, AFAICS. Since it performs an excellent unification of both internal (memory-intensive) and external (networking, hard-drives) I/O routines, AND it allows the explicit use and control of higher-performance low-level OS primitives AND it’s easier to use than old IO!

Shrug. Only suggested it anyway because no-one else had come forward with other suggestions :).

Hm. Your the first person I’ve heard say that, I sure hope its true :slight_smile:

I’m probably biased and a bad test case since I did a LOT of old IO before NIO was available.

…so read through the articles :), and have a go at using NIO as described. In general, I find it’s a less obtrusive and more natural set of paradigms.

Well the socket stuff is much mroe berkeley with which Im quite familiar. Im stil ltrying to figure out the buffer stuff fully though so gimme a pointer and I’ll read :slight_smile: