Saturday, April 30, 2011

Does Compute

So, while the program was daunting and confusing at first, once I knew what it was supposed to do, it was very easy. We have used similar things many times before. We use this style for queuing up events in our game, except they were read from a Lua file. Needless to say, I find this very fun.
I probably should have broke everything up into separate files, but I just kept adding, thinking it would be the last thing until it got massive. It all works though and I guess they sort of belong together anyway. I have similar set ups in my other project where I am doing this very similar set up as I mentioned.
I am sad I did not use the as -- reference, method, keyword? -- but casting worked with me having to do less work and less editing the test. I wanted to avoid editing the test, but I had to, there was no way around it. Everything works though and it looks pretty so I am happy.
I am still very confused about the dump function. I have an idea of what it is supposed to do, but the method signature provided would make it useless and I don't feel like editing it so I just had every method do its own printing. I hope Keenan doesn't mind. Plus the way the test is set up, it has to be public, and yet it - I don't know, it's just a mess so I didn't use it.
I'm excited to get this final project underway! :D

Sunday, April 24, 2011

Bonjour

So, I was a bit worried because I was pretty sure we had homework, but did not check until shortly before I needed to get ready for my vacation to France. I had not started and was intimidated by the assignment. I tried to write some of it on the train, mostly copying the Microsoft tutorial with the patchy T-Mobile Internet while I was within German telephone service. I wasn't able to run it successfully and assumed it was because I didn't have internet on my computer, just my phone. But we had an early night and I was able to use the free Wi-Fi.
I was having problems getting it to connect to each other. Finally, Shervin mentioned something about Keenan's code which I did not understand at first. I eventually tried digging through the files on Perforce and found a sample of the program. It worked much better than the Microsoft tutorial and I used it and the program was mostly done.
I was so happy to see the .sort() function did all the work for me. I had earlier tried to figure out how I would send all the data. For whatever reason, I first thought to put the list into an array and send the one array at once and reassemble the list. I am glad I had time to think about it and use this far superior method.
I finally got the programs sending data, but I was getting random packets of 20s at the beginning so I made packets which came before every packet which said it was a valid packet coming next and that did the trick. I was quite happy. All in all, this program made me very worried and then very satisfied. There are a lot of optimizations I could make, but for now, this will do.

Tuesday, April 12, 2011

I Feel Like Class Cat Would Have Better Suited With A String

So, I finally finished. I remember Keenan saying something about not using loops or being more imaginative, but I - I just figured it out!

I just fixed it. It looks much better now. I can think of one more optimization, but I don't think I care enough to make it. Also, I should probably comment more, but I have decided against it. I am pretty sure you destroy the object when you serialize it, so that's what I have been doing.

Not too many problems on this project once I learned of memcpy.

Monday, April 11, 2011

Cocky Corbin

Alisa would love this title. At any rate, I originally thought this assignment was easy. Now I know it is, but for a bit I was a bit confused on how to do it right. I tried a few things and after looking through the lectures I believe I finally got it. I'm only halfway done, but I don't think the other two will be a problem.
The biggest problem is the IDE. It seems intent on hiding all the commands I want. Perhaps I have the Express version. I wish the MSNDAA would get back to me on giving me another copy of Ultimate...