![]() |
No Operation Games Presents
|
|
|
Home
|
Development JournalI'd like to talk a little about what challenges were involved in making this game and what choices I made.ModelsI decided to use the .X file format for the models because there appeared to be a decent amount of support for it in the different 3d tools that my artist was using, and the most important thing is that there was code readily available to load these files in.The first thing I did was to encapsulate the code into a class (which I called DXObject if you're reading along in the source code). An additional benefit is that I was able to find tutorials showing how to implement animation using the .X files. I have implemented this, but I do not currently have any artwork which exploits it. This I did by extending the DXObject to DXAnimatedObject. Scene LayoutOnce the program moved from the phase of "Hey look, I've got a 3d object on the screen" and into a real game, I found myself constantly tweaking locations of this and that. My artist suggested that I use a file format such as .ASE to manage the locations of all of the objects.So the first thing I did was start writing a parser for .ASE files. It's a pretty simple format, so the parser was not difficult. We decided to represent the locations of the objects with "Dummy" *HELPEROBJECTs, which were bound to the real objects in Max. The reason we did that was because I didn't want to rewrite the code to import the models from the .ASE file, and I didn't want the unneeded geometry cluttering up the .ASE file and taking up memory and loading time. Once we agreed on nomenclature for the objects, it was really easy to get everything working. The downside to this is that we're stuck using Max to lay out the scene. My artist is not really fond of Max, and there are some tweaky things we need to do in order to get everything exported consistantly. I'm going to examine .XSI files next and either write a simple converter to convert the elements I need to .ASE file or I'll rewrite the importer. This decision will depend on whether or not there are any benefits to using the native .XSI file. Light my FireThe lights were another issue with Max. I could not find a good translation between the way that DirectX handles attenuation and what was being exported from Max. This is one of the things I'm going to look for in the .XSI files to see if I can make more sense of the attenuation data and match what I display to what was originally created.The one real victory here was the fire effect. I simply randomized the attenuation of a nice warm light near the building and it completely changed the character of the scene. Although this is not your typical flames and smoke type of effect, I'm really happy with how much "fire" feel it gives, and can only be enhanced by other effects I may add later. PhysicsI precomputed a path for the babies to travel by doing a simulation using a starting position, gravity, etc. I'm not extremely happy with this set up because it requires constant tweaking every time I change some of the starting parameters.For example if the starting position moves higher, it changes where in the final curve the babies enter the ambulance. So, I have to tweak the gravity until it matches back up again. But this was faster than a more mathematical approach and I had a deadline that I wanted to hit, so I'm stuck with tweaking until I have more time to re-open this issue. |
|
|
|
||