|
CG Madness - progress blog
|
|
8 entries
| 1 |
» lyz984 from Berlin, Germany |
02/03/2008 at 23:36 am/pm(?!) |
|
After another week of hard work the game looks exactly the same, but has a new menu structure under the surface that looks a lot more like C++ than before. This will hopefully help to add the missing menus for the upcomming first release of CG Madness with network support.
Finally someone responded in the guest book, and comments like this let me think that the project is worth the time I spend on it. |
|
 |
| 2 |
» De Borger from Brazil |
26/02/2008 at 10:26 am/pm(?!) |
|
Very nice man! This is better than some shareware clones of MM! |
|
|
| 3 |
» lyz984 from Berlin, Germany |
24/02/2008 at 14:11 am/pm(?!) |
|
First, there is now a server build into the game, so everyone can start a server without using the command line. It was exactly as simple as I thought. The server thread is just running in the background of the game like the dedicated server would do as a seperated process. Of cause this necessitate to tell the client where to connect and this is now possible through a simple input line in the game menu.
Second, until now the protocol beetween all client was composed of just a single type of message. But while the game grows there would be more different message types. So I implemented a remote procedure call (RPC) system with a simple interface definition language (IDL) compiler. I already tested the system by adding a new simple command and it worked very well. Adding a new command is just adding a line to the IDL file and adding the implementation to the recieving module. Network code like converting parameters into a data stream and back on the other side is generated automatically by the IDL compiler. |
|
 |
| 4 |
» lyz984 from Berlin, Germany |
17/02/2008 at 1:09 am/pm(?!) |
|
A small change did the trick. Instead of only sending the position, I send position and velocity, so the other side could extrapolate the ball until the next package arrives. It also saves a lot of bandwidth to send data in binary than in plain text.
The first application, a viewer, was very successfully tested. Even throug a proxy it seems that movement could be transfered fluently. So went on to the next step. A sandbox game mode, where all players can see each other in the same level. For the moment there is no collision detection between players, but it already works very well. |
|
 |
| 5 |
» lyz984 from Berlin, Germany |
15/02/2008 at 0:06 am/pm(?!) |
|
Now there is an dedicated server, that will hopefully be very helpfull in testing how to deal with firewalls and such. Also I noticed that the build-in server, that the game should have for simplicity, could just be the dedicated server running in its own thread. That way both servers will share the same code, so they will always be up-to-date.
To create this dedicated server I had to recycle some of my old thread code to avoid busy waiting.
I also added my template extention to the build system, so template classes can be defined like normal classes with declaration in the header file und implementation in the cpp file. |
|
 |
| 6 |
» lyz984 from Berlin, Germany |
13/02/2008 at 23:40 am/pm(?!) |
|
After some more hours of debugging libgrapple I found the last two places that needed to be changed to work with windows. Due to the partly good design of libgrapple, these were the both single places where data is recieved or send.
Unfortunatly it there is a leak of performance since these changes, because it's not fluent anymore, even not on the same computer.
But I will definitely have this leak of performance over the internet, so I should optimize the protocol anyway. |
|
 |
| 7 |
» lyz984 from Berlin, Germany |
13/02/2008 at 0:38 am/pm(?!) |
|
It seems that nobody wants to write to the guestbook, so I use it to blog the progress on the game. Feel free to post comments.
At the moment I build the network library libgrapple into the game, to make it multiplayer capable. Unfortunately this lib is only usable for linux, but it is exactly what I was looking for, so I try to port it to windows by myself.
But this turns out to be harder than I thought, because windows socket programming differs a lot from Linux socket programming. |
|
 |
| 8 |
» lyz984 from Berlin, Germany |
19/01/2008 at 11:42 am/pm(?!) |
|
Welcome to this guest book! Please give feedback on how you like the game or what features you would like to see in the future. |
|
 |
|