Saturday, September 10, 2011

Long day

I worked a lot today.

Rewrote a lot of code AND got light to travel through doorways. I know, pretty awesome right?

More re-writes

So, the current "game" that I am working on takes place in a suburban home. When I last posted, I had figured out how I was going to create the doors and allow the player to interact with them. This morning, I implemented it all.

Now that a part of a room can be interacted with, I need to be able to relay the current state of the door back to the user. This means that I need to constantly update the room's description to include which doors are open or closed. However, before doing so, I think it's best if i finish the lighting functions first, since this too will effect a rooms description. What the player will see when its pitch black is vastly different than when the player is in a brightly lit room.

So I have also added in the ability to toggle light switches on and off. However, doing so doesn't actually accomplish anything yet.

Before moving on, I think I have to rewrite more code. It seems that this is a common practice lately. I believe that I want to change the way a room object is constructed, somewhat drastically. This will impact movement as well, so that will also need to be rewritten.

Also, I should comment my code. Sometimes it takes me a couple reads to figure out what a section is doing and I wrote the damn thing.

Also also, I am thinking of adding debug/dev tools into the code that can be toggled on and off.

In summary, there's a lot of work to be done before anything new gets finished. Arg.


Monday, September 5, 2011

Updates

Over the past few weeks, I have managed to get my C# code on par with where my C++ code was before the switch. With most of the bugs worked out, I came up with a neat game idea.

Before I began working on this game, I thought that I had most of the code that I would need already done. The player could move around, open doors, interact with objects etc. However, I was mistaken. While, yes, all of these things are true, those functions/methods weren't doing exactly what I needed them to do. Therefore, I am building upon existing code to make it more powerful.

For example, most of this weekend was spent on doors. The old maze/fighting application only had one door and only required a bit of extra code to handle it. This new game has at least nine doors. In order to make my code streamline, I had to throw out the little extra code I used for one door and write a block of code that could be used for an infinite amount.

For a while, if you opened Door A in Room 1 and walked through it to Room 2, that same Door A would be closed in Room 2 despite it still being open in Room 1. But that has since been fixed.

I have no idea of a timeline for this little project. But hopefully I'll continue to plug away at it.

-Dash27