Project Wish  
Project Wish
Project Wish
hardwired

Welcome Guest ( Log In | Register )

> Bugs, pointers, and crawfish
Not rated V  (0 votes)
Jul 31 2006, 12:36 AM
When one hears "bugs" and "pointers" in the same phrase, one tends to associate them, at least if you're a C or C++ programmer. Today was one of those rare cases when the bugs were not tracked down to pointer problems (well, all except one).

I fixed a few annoying bugs in Dwarf today, the most annoying being the program crashing anytime you released the left control key. I traced it down to some code that was apparently outdated and depended on a pointer being initialized, which it wasn't. I put a guard in there to get rid of the problem and then commented the call out because I don't think it actually made anything happen in the editor anymore. Bug 1 down.

Another problem was a bit trickier to catch. Apparently in CEGUI if you drop down a list box and click away from it so it hides the list, it doesn't get a deactivation message. This caused the list box to not get clipped by the parent window when it was rolled up and you ended up with a list box floating around in the middle of nowhere. I realized I was catching the wrong messages and changed the code and it worked. Bug 2 down.

Another bug had to do with the way the editor starts up. It depended on a default map to be present, and also had two different paths for loading a map, one dedicated to the first time a map was loaded, and one for the rest of the time. This caused a problem where the settings wouldn't be in sync with the world. It was a pretty simple fix to get the map to load in by calling the other code path and adding a reset function to the settings that would update the settings to the current environment. Bug 3 down.

So I was done with bug squashing for the day, but it was still early so I decided to finally get rid of all raw pointers and replace them with boost's scoped pointer. Normally this is an easy task. Unfortunately for me Dwarf has a bunch of header files that include eachother and a couple global variables. Pointers were used throughout the classes though so it compiled. But when I changed over to the boost pointers i needed the actual object, not a pointer to it. So After about 30 minutes I hashed out a fix to the headers and started the boring task of coverting, compiling, and testing, which lasted about 2 hours.

After all of that I was ready to wrap it up for the night. I had forgotten about a simple feature I was going to add. I wanted to make the titlebar reflect the name of the map that was currently open. I guess I'll get to that later.

On to the personal stuff. Why am I feeling beaten up? Well, it's not from the development I did today. That was fairly easy stuff. I had a pretty big weekend though.

Friday I played Nazi Deathfest (or Brothers in arms as it's more commonly referred to) with a friend of mine. We beat all the skirmishes on the advanced mode and we're ready to go up to the veteren setting. There was this one mission called "Defending the Line" where you play as the Germans and you have to clear wave after wave of Americans. Towards about the halfway point you get pushed back to a bombed out house. It was at this point that we realized there were 4 squads (each squad with 3 men) coming for us. They converged in the trenches in front of us and did an all-out charge up the center. My friend picked up a BAR from a dead American and I had the FG-42. We fired until our clips ran out, blinded by the muzzle flash. When I ran out I was facing a wall and looked outside the window in time to see the last one fall dead. Thankfully we had both of our sqauds with us or we would've been dead.

Saturday was a great day. Got up early to prepare for Cajunfest, which is just a big pot-luck picnic where you get some of the best cajun food for free. I made black-eyed peas with smoked pork butt, which also made a very good warm chip dip. At the festival they had some excellent food. They had shrimp, crawfish, salmon, marlin, seafood creole, cajun lasagne, chicken, meat pies, spaghetti, and probably some things I can't remember. For dessert we had a variety of things, including rhubarb pie, rum balls, two-ton burbon cake, boiled peanuts, mini pecan pies, and some other dishes I can't remember. I probably can't remember a lot of stuff because there were 3 kegs of beer there, to which I was very fond of.

Saturday night was also fun. I got together with a couple friends, had some good beers and used the shitty ones to boil brats in. The brats we had were supposed to be Wisconsin's best, and they were damn good. I don't remember a lot of the night because we had quite a bit of beer. I think one of my friends and his girlfriend kept sneaking off to make out somewhere.

Sunday morning we got up and went to this place in Oconomowoc where we had Belgium waffles al la mode with whipped cream and syrup. Usually they offer chocolate sauce for it as well, but they didn't today. After that we went home and I started working on Dwarf.

My cold is finally clearing up too (and thankfully the swelling has gone down). Now it's time to relax for the rest of the night.
Go to the top of the page
  Print

> Comments for: Bugs, pointers, and crawfish
No comments to display

RSS
> Info/Links
About the author
njpaul



PM   Profile Card
Blog categories
Blog stats
Views: 18409
Entries: 55
Blog created: Nov 23 2006, 01:25 AM


Lo-Fi Version Time is now: 23rd September 2021 - 09:55 AM
Original skin by: b6gm6n | Conversion by: Chris Y
hardwired
  hardwired
hardwired hardwired
hardwired hardwired