Blitzmax GameNet confusion.

BlitzMax Forums/BlitzMax Programming/Blitzmax GameNet confusion.

Ryan Burnside(Posted 2010) [#1]
*** This may need to be moved into Beginner section***

I'm a little confused on how GameNet is used in several areas. Now I do not want to make some pie in the sky MMO game I simply would like to create a game that plays on a LAN for up to maybe 4 or so people. I think I will start by making a game in the style of TANK for the Atari 2600.

1. My first question deals with the server-client model. From the examples that come with Bmax it looks like every player must create their own "host" object. How then is data shared between computers? Is there a host that processes all clients or does everyone have equal shared processing?

2. The included examples will run multiple copies of a program on one machine but I'm not totally sure how to set up players using the necessary data needed.

3. It appears that the GameNet objects contain some field slots but I'm not quite sure how to bind these Gnet objects to my player objects. I would like to stay OOP if possible. The included example does all of the calculations outside the Gnet objects without any OOP style data storage. Everything is just sort of floating loose around the main loop.

I've not taken any networking courses at the college nor do I have much experance but I would really like to find a way to make suitable small scale games for PC. I've been using Bmax for about 3 years with great success but this online play is sort of an enigma to myself among other people. It seems an area that people just know how to do or they don't.

This is the source from the included demo. I'm still wondering the general process for synching objects and object to object interaction.




Dreamora(Posted 2010) [#2]
gnet automagically syncs all fields on gnet objects, no control over what and to where.

thats why its normally avoided by most users, as it generates massive overheads where not even remotely needed


Ryan Burnside(Posted 2010) [#3]
Ok, so has anyone written a concise Blitz tutorial aimed at somebody like myself who has no prior online programming experience? I suppose the second library mentioned with sockets would be helpful since you say GameNet is not the best tool.


Bremer(Posted 2010) [#4]
Leadwerks made some network code available recently that might be something that could get you going.

http://blitzmax.com/codearcs/codearcs.php?code=2639

It seems to have the features you are looking for.