Fixing Bugs

Screenshot!

As you can see, I increased the base size of the entities. The collectables were too hard to see, and the new size of everything is acceptable.

I fixed quite a few bugs today. Among them was the Door Bug (seen above). With this bug, I originally had it so that when you opened a door, the ClosedDoor object would create an OpenDoor object and kill itself, and the reverse for closing an OpenDoor object. (I know it was a terribad idea, shut up.) When an entity dies, by default it drops all of its inventory. All blocks contain one item of themselves, so that when you break them down, you can pick them up again.

When you opened a door, it would drop a door collectable. Alot of the time, the collectable would be inside the door, so the door would stay open, but if you had two doors next to each other, one might drop a door collectable into the other, which would then drop a door item of its own… and if those two pushed each other out of one of the open doors, the door would close and create another door item.

I froze the game one time, screwing around with the bug – it had created a big pile of like 10+ door drops and got stuck in some infinite loop somehow. It was sooo crazy. Notice that one of the monsters chasing me in the screenshot above has picked up 16 doors. Yeeeeaahhh.

I cleared some other crappy bugs not worth mentioning, as well. One bug I haven’t bothered with yet is shown below:

I placed the Town Crystal, upgraded an NPC, and was going to pick it back up… but when I broke down the Crystal, the NPC was touching it and picked it up on me! While I’m not pleased that they can, I’ll leave that alone for now.

Let me direct your attention to my inventory: Notice how there are 3 stacks of stone wall items? In code I’m actually giving the player 200 of them in one shot. The code will only add it in stack-max format. I’m happy at how well it works, even if it’s a simple thing. Sometimes it’s the little things that count.

I also realised recently that I needed a file with the current bugs written in it, and I need to write the bugs in there as soon as I find them, or 1) I won’t remember the bug later, and 2) I won’t be able to find the bugs I need to fix as easily. It seemed like a good idea, and it turns out it’s helping me quite a bit.

I have enough of the irritating bugs out of the way now that I can move onto the thing I want to do next: parties!

Advertisements

Tags: , ,

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s