Okay, so this week I have been trying to make pretty decent drawable object code base for the new OpenGL version of ZT. When talking to Anthony( the once-again artist for the game ), we decided that just billboarding everyting isn’t enough. At first, I thought it would be acceptable, but Brian suggested that since I am using this powerful new tool to develop, why not make it so the user can rotate the map. I thought this was a good idea. I then realized that it would cause problems with my billboarding scheme. Houses, for instance, would have just been 2d objects in my world, and rotating around them would have given a really odd appearance to the game that I could not have. So I decided that I would make two kinds of objects, billboarded and 3d. The 3d objects would be broken up into pieces( pillars, if you will ) that each tile would contain one of. This sounded alright, as it is essentially how the game does it now anyway. But I got to thinking and thought, I wonder if the criss-crossed method that some games use for trees would look good? This method is essentially taking 1 2d object and drawing it once in the XY plane and then again in the YZ plane. For some objects, like trees, it does look really good, even better than the billboarding method. So now I was up to 3 object types, billboarded, criss-crossed, and 3d. I then thought, “signs and fences really don’t fit any of these types,” and decided I would make a 2d object that would not rotate with the camera. The object can be any combination of the 2 dimensions, so it allows for say.. bridges over water( albeit very flat ones ). So I was happy then. Then I remembered that it was a pain in the arse when I was using the map editor to have to place the 12 individual pieces of my 3×4 tiled house, so I made a 2d world object class and a 3d world object class. Both of these classes are drawn independantly from the tiles theys sit on, meaning that if one tile were suddenly gone, the piece of the object on top of it would still be drawn, this is different from the trees, say, as they are drawn by the tile, not the world. That really doesn’t matter, though, considering tiles won’t just go disappearing anyway. I am thinking that with these 5 drawable object types, I should be okay to implement any kind of objects that I want in my game. It will also make my map editor a lot nicer and more user friendly.
Speaking of the map editor, I have decided to make this version of it( whenever I get around to it, 3d picking is HARD ) a lot more scalable. For the 2d and 3d world objects, I am going to allow the loading in of textures for each one to be done while the editor is running, this way each house can be different. And I can also make the trees varying heights in the editor, so even though they have the same image being drawn, they can be different heights. This will allow for more variation in the trees. That’s a good thing. We already have variation in the trees already because Anthony and I think we should have several different drawings of say evergreens that the game will randomly pick at either run time or when the map data is written to file. Either one works for me, though the former might end up with observant gamers noticing that one tree suddenly became another when s/he left the map and came right back, probably not too big a deal though. So, right now I am thinking one tile’s entry in the map file might look like this:
That is the tentative data that any one tile will need. So if a map is 100×100 tiles, there will be 10,000 of these entries. That could get big in size. I might have to assign the file textures and drawable object textures a number for each path. Sorry.. babbling. Essentially once a tile is created, an opened file will be sent to it, it will read the necessary information from the file, then create it’s drawable object, the drawable object will then take from the file what it needs, and be done with it. This sequence should be pretty easy to put in place, so I am pumped.
I just gotta manage to figure out 3d object selection… bleh.
Okay, enough geeky-programmer speak. This week is finals week. Most people loathe finals week to no end. They study for what seems like an eternity and still think they will fail. I, on the other hand, decided long ago( when I was a freshman ) that if I got good grades on all of my tests prior to the final, then the final, which is just a review, should be easy. This ideology hasn’t failed me yet. There are some classes that I wasn’t doing so hot in and as such, I was nervous on the finals. This semester I had no hard finals, so I wasn’t really all that worried. I took all three of them with stride, and am now in Morgantown until Friday when I am done working. This is good and bad. Good because I like making easy money, bad because I don’t get to see my beeb. Boo to that!
Time alotted for finals: 500 minutes
Time spent on finals: 55 minutes
Damn it feels good to be a ganster.