Friday, June 8, 2012

The Final Project The Final Weeks

Right... So about this blog... Yeah I forgot to update a few times, but I didn't really do anything... Hopefully this massive post sort of makes up for it? So I am not gonna lie. I messed up pretty hard. When it came to this class in the end. I literally did exaclty what you told us not to do. Wait until the last moment to get the project done. Well. I still somehow finished and I am actually quite proud of it. I had a lot of troubles with it early on this week. One of the first things I wanted to do with the program was get it so tha the machines could connect. I first tried basing it off of the code for the networking take 2 stuff which was uploaded to the common by another student. but I quickly realized that that was a horrible idea because it was incredibly, incredibly convoluted and non transferable. I then saw the god like code called p2p example and quickly switched to using that. That was day 1 of my struggles. Day 2 I spent all day trying to get the two machines just to connect to each other. A simple, make session and join session. I would make the session, but then I could not join it for the life of me. I couldn't figure it out until the next day. Early that next day I realized that I needed to called networkSession.Update() every frame, otherwise the remote player would never find the game at all. So I fixed it and I praised god that I finally made visible progress. I then spent the rest of that day getting it so that the player ships would move around. It turned out to be pretty simple since the p2p code was so visible. The next day, day 4, also known as Thursday was interesting. I found out that the game was due at Noon on Friday. I was worried a bit, but I didn't let it stress me out too much. I just got too work. I was quickly able to get the ships to fire and lay mines. I had a good idea of how I wanted to do it and it turned out not to be all that bad for my implementation. I don't know if what I did was bad or not,but it works fine on a system link connection. Then came the biggest part of the problem for me, the data-driven conversion. I literally did not know what to do for this. I was really confused on how to do it. Luckily I met with some other people from the class and just chatting it out with them, turned out to help with my ideas. Glad I was working near others doing the project. I also then found out about all the extra stuff such as the checklist and video and stuff then. I got to say, I was pretty confused. Whatever, I got those done right before typing this up. Anyways, I was still confused on the data-driven. It's not that I don't know what it is or anything, I was just confused on how you wanted it done. The instructions were pretty vague so I was just kind of doing stuff. I found that somebody had posted code which had a super solid queue class on it. So I implemented into my game. That saved a crap ton of time. I then implemented a two queue system. A get queue and a receive queue. The get queue gets the inputs from the handle function and then calls them and updates the ship. The The packet writer then uses the newly updated ship variables and player variables and sends them through to the remote player. The remote player gets that information and then writes them all into the receive queue. The receive queue then processes and puts the information where it needs to be. I think that it is pretty data-driven. It implements queue's at least. I should also mention that it was a pain in the freaking ass finding a second computer to work on. I had to use a combination of the game dev lab, which was only updated because I directly asked the admin's to their face for help and my friend sam's computer to get it all done. God, I don't know how many times I had to set-up the environment this week. It was too many, but now I know that this is an issue. Learning. It is a good thing. On a final note, I am never taking 5 classes in one quarter ever again. TOO MUCH WORK. I will say that that was the sole cause for me messing up a lot of stuff for not only this class, but others too. I will say though that, through my struggles this quarter, I learned an absolute TON of stuff. I feel a lot more prepared for doing the DGE game after taking this class. I feel I proved to myself that I can figure this stuff out and do it. So I thank you for teaching the class. I found it to be fundamental to my understanding of not only network programming, but just programming in general. Thank you very much, William "Frank" Deaton