Followers 0
• entries
37
46
• views
21813

## ..............

Okay, so I've been away for a really long time. I had to take three standardized tests in a row, and I'm only two-thirds through. Also, due to the fact I have no discipline or motivation at all, I'm giving up on my latest RPG project. I have seriously tried to make a simple 2D RPG at least two dozen times, in the past several years, and I have never even got close to having a playable game. Well, it's not so much a lack of discipline as a lack of skill. I always get up to the point to where I need art to test, but I'm not a good artist. I don't want to work in a team, so I start trying to draw my own art, but it's awful, and I get demotivated. I always end up buying some book on how to draw, making no progress at all, and trying again, but with built-in demotivation because I failed last time.

Not this time though, this time I'm doing something different! I have discovered that I find computer engineering more interesting than software engineering, so I want to build my own game console. I bought "The Black Art of Video Game Console Design" by Andre Lamothe, to go with my X Game Station. I had the original e-book, but it was impossible to read the stupid hand drawn diagrams (which have been replaced in the book), and also I just hate reading e-books. The only problem is that Andre is a terrible teacher. I don't think I have seen worse explanations and more misleading comments in my life. But, in spite of this, I am learning, and thanks to a lot of helpful people on gamedev helping me overcome a mental block with electricity in a recent thread, I'm ready to get started in the world of microcontrollers.

I'm going to build an SX-based game console, but different from the xGameStation. What I really wanted to do, was to build a 6502-based system, but due to their prices, I'm going with an SX-based system, probably using the SX28 DIP version so I can use a breadboard with it. I was thinking of adding a dedicated video processor so the main cpu doesn't have to generate an NTSC signal, which is really lame. I was also thinking of using a better sound system, like the one used in the Hydra (which I may also get), because the sound system in the XGS sucks. Oh, and I want to add ROM cartridges too.

So anyway, I know I'm not going to give up on this because I haven't been so excited about a project in a long time, and my excitement has stayed for more than a month, which is more than any of my game projects.

## Untitled

So I haven't put anything in this journal for a long time, 'cause nothing exciting has been happening with me (unless you call playing Baldur's Gate for the billionth time exciting).

But now, I'm working (again) on a game engine. Woo.

But this time it's different for the following reasons:

• I am not planning this at all, I will just refactor as necessary.

• I am making content as I need it, not all at once (big sticking point).

• I am using C# and XNA.

• I am better at programming.

So I'm going to have fun doing this without too much forward planning, and seeing how playable it is.

Anyway, the first thing I started on were the gameplay classes, because they're more fun to make than graphical classes.

So the most important game play class is the entity (I started spelling game play as two words because Firefox's spell check is yelling at me) because it represents something that can be interacted with.

Every entity has two parts: its sprite, and its other stuff. I couldn't figure out a name for the other stuff so I called it "EntityReference".

using System;using System.Collections.Generic;using System.Text;using System.IO;using FromNothing.Utility;namespace FromNothing.Gameplay{    class EffectValue    {        string idName; //must be unique        string visibleName; //what the player sees        double Magnitude; //how strong it is        long Duration; //how long (in milliseconds) it will last    }        //this class specifies all the information about an entity that I might want to save.    //Any thing in the game world that can be interacted with is an entity.    class EntityReference    {        //This MUST be unique, it is used to identify an object        string idName;        //This does not have to be unique, it is what the player sees.        string visibleName;        //This refers to the type of object that this actor represents. EntityTypes might        //be "door", "tank", whatever        string entityType;        //Every actor has various attributes and statistics associated with it.        //This dictionary maps an attribute name with its value. Examples of attributes        //would be "strength", "dexterity", and "hitpoints", or in the case of a door,        //"thickness", and "picklock difficulty".        public SortedDictionary<string, Variable> attributes;        //Attributes are variables that are always present and relate directly to gameplay.        //They never go away. LocalVars, on the other hand, have distinct lifespans. These        //might be used to track plot points involving an actor.        public SortedDictionary<string, Variable> localVars;        //Effects are temporary ailments that are capable of effecting all entities, not        //just ones with specific storyline purposes. They are usually very temporary.        //Examples of effects include "poison", "lung shot", or "on fire".        public SortedDictionary<string, EffectValue> effects;        //Actions Performable are luachunks that spell out what happens when a character        //performs a certain action on this entity.        public SortedDictionary<string, string> actionsPerformable;        //if the variable does not exist, it is created.        public void SetAttribute(string name, Variable value);        public void SetLocalVar(string name, Variable value);        public void SetEffect(string name, EffectValue value);        public void SetActionPerformable(string name, string luaChunk);        //there is no kill attribute because attributes live until the character is removed        public void KillLocalVar(string name);        public void KillEffect(string name);        public void KillActionPerformable(string name);        /////////////////////////////////////////////////////////////////////////////////        public Variable GetAttributeValue(string name) { return state.attributes[name]; }        public Variable GetLocalVarValue(string name) { return state.localVars[name]; }        public EffectValue GetEffectValue(string name) { return state.effects[name]; }         /////////////////////////////////////////////////////////////////////////////////        public void Serialize(Serializer serializer);        /////////////////////////////////////////////////////////////////////////////////    }    class Entity    {        public EntityReference reference;        public Sprite sprite;        Entity()         {            reference = new EntityReference();            sprite = new Sprite();        }            }}

Anyway, if you see anything that sucks, let me know. I'm going to be a game developer some day, and if you don't help me now, karma dictates that you will be maintaining my code some day.

## Untitled

So I haven't put anything in this journal for a long time, 'cause nothing exciting has been happening with me (unless you call playing Baldur's Gate for the billionth time exciting).

But now, I'm working (again) on a game engine. Woo.

But this time it's different for the following reasons:

• I am not planning this at all, I will just refactor as necessary.

• I am making content as I need it, not all at once (big sticking point).

• I am using C# and XNA.

• I am better at programming.

So I'm going to have fun doing this without too much forward planning, and seeing how playable it is.

Anyway, the first thing I started on were the gameplay classes, because they're more fun to make than graphical classes.

So the most important game play class is the entity (I started spelling game play as two words because Firefox's spell check is yelling at me) because it represents something that can be interacted with.

Every entity has two parts: its sprite, and its other stuff. I couldn't figure out a name for the other stuff so I called it "EntityReference".

using System;using System.Collections.Generic;using System.Text;using System.IO;using FromNothing.Utility;namespace FromNothing.Gameplay{    class EffectValue    {        string idName; //must be unique        string visibleName; //what the player sees        double Magnitude; //how strong it is        long Duration; //how long (in milliseconds) it will last    }        //this class specifies all the information about an entity that I might want to save.    //Any thing in the game world that can be interacted with is an entity.    class EntityReference    {        //This MUST be unique, it is used to identify an object        string idName;        //This does not have to be unique, it is what the player sees.        string visibleName;        //This refers to the type of object that this actor represents. EntityTypes might        //be "door", "tank", whatever        string entityType;        //Every actor has various attributes and statistics associated with it.        //This dictionary maps an attribute name with its value. Examples of attributes        //would be "strength", "dexterity", and "hitpoints", or in the case of a door,        //"thickness", and "picklock difficulty".        public SortedDictionary<string, Variable> attributes;        //Attributes are variables that are always present and relate directly to gameplay.        //They never go away. LocalVars, on the other hand, have distinct lifespans. These        //might be used to track plot points involving an actor.        public SortedDictionary<string, Variable> localVars;        //Effects are temporary ailments that are capable of effecting all entities, not        //just ones with specific storyline purposes. They are usually very temporary.        //Examples of effects include "poison", "lung shot", or "on fire".        public SortedDictionary<string, EffectValue> effects;        //Actions Performable are luachunks that spell out what happens when a character        //performs a certain action on this entity.        public SortedDictionary<string, string> actionsPerformable;        //if the variable does not exist, it is created.        public void SetAttribute(string name, Variable value);        public void SetLocalVar(string name, Variable value);        public void SetEffect(string name, EffectValue value);        public void SetActionPerformable(string name, string luaChunk);        //there is no kill attribute because attributes live until the character is removed        public void KillLocalVar(string name);        public void KillEffect(string name);        public void KillActionPerformable(string name);        /////////////////////////////////////////////////////////////////////////////////        public Variable GetAttributeValue(string name) { return state.attributes[name]; }        public Variable GetLocalVarValue(string name) { return state.localVars[name]; }        public EffectValue GetEffectValue(string name) { return state.effects[name]; }         /////////////////////////////////////////////////////////////////////////////////        public void Serialize(Serializer serializer);        /////////////////////////////////////////////////////////////////////////////////    }    class Entity    {        public EntityReference reference;        public Sprite sprite;        Entity()         {            reference = new EntityReference();            sprite = new Sprite();        }            }}

## Back

I just got back from China.

Here is a list of weird crap that I ate:

-Sea Cucumber
-Soups made from various parts of the lotus plant
-Chicken Feet
-Tripe Sausage
-Duck's tongue
-Jellyfish
-Pork Gellatin
-A whole fish (literally)

The general rule in China is to not ask what you're eating. It's dangerous.

Okay, now that I have had a huge hamburger, I want to work on another game that I probably won't finish. The game will not use XNA, even though I was really excited about it, because I would rather learn how to use Managed DirectX.

All I know is that the game will be an RPG. It will be set in a fantasy/sci-fi universe. And it will be sort of like crono trigger, except with a more tactical battle system.

I know, I know, don't use all your creativity all at once [rolleyes]

I figure it will help if I post every time I start a part of the game. Like, so I can get suggestions. I'm not sure what the ideal order for working on stuff.

I plan on creating several interfaces to simplify the parts of my engine:

-Resource
-Subsystem
-DataStore
-DataAccessor
-Game

Anything that the player hears, sees, or anything that is rather large and needs to have specific lifespans will be a resource. Graphics, sound, animations, scripts, and anything that will load from my custom resource file format is a resource.

Subsystem should be pretty obvious. It's a game system. The Game interface will have a method that allows it to add subsystems, which it will then tick as often as possible.

Datastores are what allow different subsystems to communicate with each other. I only plan on using one, but I'm not making it a singleton because it's perfectly reasonable that you might want different subsystems to share different data with each other. Basically, the data store is a collection of lists of Events. Event looks like this:

struct Event{  public string subsystem;  public string type;  public Object data;}

That's it.

The datastore simply adds events for certain subsystems, and it's up to the DataAccessor to search it's list for events, and then report that to the subsystem.

Anyway. I'm jetlagged, so that may be totally incoherent. If it isn't, I would realy, REALLY like to hear suggestions for, or problems with this design. Please comment!

## I'm finally back

It's been a while since I wrote an update. I finally have internet access since moving into the president's mansion on campus here, with a shiny new 3 megabit connection (I realize the rest of the world snickers at this. Stop snickering and get me a 10 megabit connection). I really didn't have a lot to do programming wise. I was just working on random sprite projects, when BAM, XNA comes along. Out of curiosity I downloaded the beta, and was blown away by how awesome it is. Seriously, the component system is awesome, and I've been waiting for an excuse to use more C#.

I'm going to be totally trying out this platform, and maybe making some games instead of inventing wheels. I finally dropped that old way of thinking. I couldn't stand not to make everything myself, but I've realized that I always failed to make it well because I didn't really know how it should work. With XNA, I can take other people's components and easily integrate them, so my old excuse of having to learn someone else's unintuitive system won't work anymore.

About a week ago I got back from the National Youth Leadership Forum: Technology. It was pretty cool. I got to tour the nVidia HQ and listen to a seminar by Blake Ross, who was a great speaker.

I'll be moving to 'bama soon, this friday in fact. I'm in the process of cleaning out my room, throwing stuff away and such. I can't wait, our house will be really nice, and I'll be on the college's fiber optic line, but it will be very fast because the college is so small. The only problem is, the house is being renovated, so we have to stay in an apartment room a month until it's ready. I have lived in an apartment before, so it's no biggie.

I am currently working on a program that is sort of like Rpg maker, one of my favorite things as a 10 year old (that was when Rpg2k came out, I loved it). I have tried this many times before, but I always failed to make my own scripting language. This time, I'm integrating Lua, so that obstacle is no longer present.
Lua is a really great programming language. It's very simple, and pretty easy to integrate. The only drag is that Lua stack, which I find rather confusing. I think there should be two stacks, one for Lua to communicate to C++ with (Writable by Lua, Read-only for C++) and one that is the opposite. I don't like having only one stack for both purposes, I'm never sure whether to pop something, or whether it is automatically consumed. I think the Lua documentation is horrible also. It doesn't even show all the functions, or at least make them easy to find.

I am mapping out what the final project will be like. I want to sell a more powerful version when I'm done. Probably shareware. This would be a really cool thing to complete before I go to college. I could also release the engine itself for free or something.

I am using SDL for Graphics, and probably SDL for sound, except Midi, which I'm writing my own library for that uses the low-level Midi api, and will support lots of cool realtime transformations. I love Midi.

Anyway, wish me luck. I have a hard time sticking with projects, but this one is one that motivates me.

## Hou zhou bu jien

I recently got back from a ten day long trip to Boston. My dad has a friend who is now high up in Chinese public health, so he arranged a conference for some Chinese scholors and did some lecturing. This is about their fourth one. I was there this time because I like Boston and some of the Chinese were here in North Carolina too before we went, so they went with us. It was an interesting experience.

The only bad part of the trip was that our crooked travel agent told all the Chinese that American food was awful and expensive so that she could send them to Chinese restaurants (ones where she knew the owner), get a huge discount, and charge it like a full meal (I'm sure she made a few hundred per meal). One of my dad's collegues had spent time in camebridge for a continuing education program, and knew a cool pub called "John Harverd's Pub" or something. He got them a reservation there so the agent couldn't do anything about it, and everyone ordered steaks and had an awesome time (if you aren't American and are reading this, our beef is awesome, especially for places like this one that serve prime beef). I think they were kind of peeved at the travel agent, who also overcharged for the rooms (more than %150 markup on already expensive rooms) and sent us to a cheap hotel just out of walking distance from where the lectures were (and where the rooms were only a little more expensive). Meh. It was still a fun trip because Boston is a great city, and I'll be going to Beijing and Shanghai for the continuation of the program. Time to buy that Mandarin Rosetta Stone package =)

_______________________________________________________________________

On the software front I've been working on a text game (I'm waiting for some books on art to arrive, and I'm not a good enough artist right now for the sprite-based game I want to make). I'm not sure about the title, but the theme will be arms dealing. After I saw the movie "Lord of War" a while ago, I thought that would be a good idea for a text game, kind of like that old Drug Wars game that was popular. Anyway, I'm still designing it, but it'll be nice to get away from messing with SDL.

Oh, and I got my ACT score back. I got a 30! Woohoo! Now I have two more times to take it to get up to the elusive 36. I'll be taking the SAT soon as well, and I'll be using the same strategy as the one I used with the ACT. Just buying a book with practice tests in it.

## Art of Computer Programming and some random rambling

I just got a copy of this three book set because I realized that not only would what I learn help me with my love of little projects like the XGameStation, but would make me better at coming up with quick algorithms and just make my code better. I have been slogging slowly through the difficult math, as I'm only 16, and haven't had calculus, or anything beyond algebra II. Giant sigmas are scary.

I have a lot of time to learn this stuff though, because I'm homeschooled and can have as much time to learn math as I want. My dad works in academia, so he's really cool about getting me books that I want. The next comp. sci. related book I'm going to get is code complete, because one of my biggest demotivators is having little clue how to design my game projects. After that, I'll probably wait until the newest revision of the Dragon Book comes out and buy that.

Totally unrelated, but I'm going to be moving to Alabama soon, to a college town called Montevallo, which is about 20 minutes from Birmingham. My dad is going to be president of the University of Montevallo, which is really cool. I'll be living on campus in the prez house, which is great because even though they're a Liberal Arts school, they have lots of Computer Science courses. Also, I'll probably try to take some drawing and some music composition classes, since those are other interests of mine.

Even more unrelated is that I just bought this sexy mouse. It's so awesome.

## Art of Computer Programming

I just got a copy of this three book set because I realized that not only would what I learn help me with my love of little projects like the XGameStation, but would make me better at coming up with quick algorithms and just make my code better. I have been slogging slowly through the difficult math, as I'm only 16, and haven't had calculus, or anything beyond algebra II. Giant sigmas are scary.

I have a lot of time to learn this stuff though, because I'm homeschooled and can have as much time to learn math as I want. My dad works in academia, so he's really cool about getting me books that I want. The next comp. sci. related book I'm going to get is code complete, because one of my biggest demotivators is having little clue how to design my game projects. After that, I'll probably wait until the newest revision of the Dragon Book comes out and buy that.

Totally unrelated, but I'm going to be moving to Alabama soon, to a college town called Montevallo, which is about 20 minutes from Birmingham. My dad is going to be president of the University of Montevallo, which is really cool. I'll be living on campus in the prez house, which is great because even though they're a Liberal Arts school, they have lots of Computer Science courses. Also, I'll probably try to take some drawing and some music composition classes, since those are other interests of mine.

Even more unrelated is that I just bought this Read more...
• 137 views
• ## Update

I just took the ACT. It was tough, but I don't think I did too horribly. I don't like how it supposedly tests knowledge, but doesn't give you enough time to finish comfortably. I knew everything on the test, but I can't read too terribly quickly (I read as fast as I talk, which isn't too fast), so I wasn't able to finish some of the parts.

On a totally unrelated note, I would like to recommend the following oblivion mods (which I haven't tested because of the aformentioned resolution):

Oscuro's Oblivion Overhaul: On paper this looks to be the best mod ever. It fixes the biggest problem with Oblivion, namely the indescriminant player-scaling. It puts minimum levels on things so that you feel weak in the beginning, BUT, it puts level caps on things so that they don't get unrealistically strong. This pretty much fixes the game's biggest problem. I will actually test it, and see if it really works this Sunday.

Inebreiation: Allows you to get drunk, with some awesome visual effects.

Af Leveling Mod: Improves leveling dramatically. Makes it to where your attributes level up with skill use instead of those stupid multipliers. It also guarentees that your max level will be 50 (if you choose, it gives you lots of options). Allows you to be more spontaneous without worrying about how you're going to level up. Makes the game much more fun.

Level Slow: Slows leveling down, which is great, 'cause it's too fast.

Natural Environments: Makes the game prettier.

Like I said, they sound awesome, and I'll test them out sunday. Can't wait!

Edit: Here's Another:

Bounty Reduction Over Time:
Slowly the guards forget about you, only if you avoid them long enough.

## The ACT

I have to take the ACT tomorrow. Because my parents are out of town, I have to get myself up at six, which is hard enough when I'm being yelled at. Anyway, I think that I'm prepared enough because I took some official practice tests which were just old ACT tests. When I finally get my score back, I'll post it if it's not too disgraceful.

Anyway, wish me luck and stuff.

## My engine

I've restarted my game engine about a billion times, but I've finally got a design that I'm sort of happy with. Since this is my first time really making an engine, I want suggestions and advice! I'm sure you all will come thru for me!

First off, I have an image class, which looks something like this (in psuedo code):

Image-------------------VideoSurface source, *destinationRect source, dest-------------------virtual Load(filename)virtual Draw()SetDestination(Screen)SetLocation(x, y)SetSourceRect(x, y, w, h)SetColorKey(r, g, b)Ctor(filename, screen)virtual Dtor

I will use an image as just a static image that wraps SDL's surface and blitting functions. Later I shall derive a Sprite class from it (hence the virtuals).

The screen they draw to is not actually an SDL_Surface, but a screen class that I created:

Screen-----------------VideoSurface surfacefriend Image, ApplicationFlip() <- these are called by "Update()"Clear()Lock()Unlock()-----------------SetVideoMode(width, height, bpp, vidMem, hwPal, dBuf, fs)Update()-----------------

Then there is the "StratusGame" class (the game engine is 'Stratus', yes I know it's corny), which should be inherited
from so that you can create your own SDL_Event handlers and
DrawScene() function.

StratusGame-----------------MainLoop() <-Called every frame, not called by the user-----------------Screen screenEvent eventbool running?-----------------static StratusGame* Initialize();bool SetVideoMode("same as above");void Uninitialize();virtual void DrawScene();virtual void HandleKeyboard();virtual void HandleWindow();----------------

That's all for now. I'm kind of worried that I'm doing something wrong, but I'm going to keep going.

Again, please comment, since most of you are more knowledgable than I.

Edit: I'll probably end up removing the Application stuff, and just writing a bunch of sprite libraries. Then I'll write sprite managers and map handling classes and see how they fit in with an Application layer.

## I hate the world

I'm an Episcopalian, and it's Lent season. I foolishly gave up video games, which means no video games for 40 days except on Sundays. I had forgotten that Oblivion would be coming out during this time. I have four more weeks. I hate myself. That is all.

## Microsoft Tech Support Sucks (and so does Linksys's)

After I replaced my motherboard, I needed to reinstall windows. All went well until I had to set up my wireless settings. I had to set my WEP key manually, which is what I normally do, but I was getting a stupid message box that informed me that I could either type in X number of hex digits, or Y number of ASCII characters. I was angry because I had tried to type the WEP key about 50 times, and it worked before. I was POSITIVE that I had the right number of digits. I made a big mistake.

After calling Micro-dollersign-oft tech support and sitting on hold for 30 minutes listening to bad jazz, I was informed of how importent my call was and then left for 10 more minutes. I was transferred to some guy I could barely understand. I'm fine with outsourcing, but not for freaking TECH SUPPORT! Anyway, I told him the problem and he asked me who made my wireless router.

I smack my forehead, because I know he's going to blame that company.

I finally told him "Linksys" after failing to convince him that the "Wireless Options" dialog box was, in fact, created by Microsoft, and no, Linksys did not magically hack the dialog box so that it wouldn't work. He ignored me and told me that he would conference with Linksys, since this was a 3rd party issue.
Ignoring my anger and his incompetence, it's actually kind of cool that Microsoft will contact the company to see if they can resolve the problem. It was strange that they had Cisco systems (of which Linksys is a division) on their list, but no Linksys. I actually had to tell him their number. Of course, the tech support costs money, and I was using one of my free trial tech calls. I can imagine that the conference went something like this:

Microsoft Guy: "Hello, this is a customer support agent from Microsoft, I would like to help resolve an issue with your software."
Microsoft Guy: "There is a problem with the WEP key dialog box."
Microsoft Guy: "No it isn't."
...10 minutes later..........yes it really took 10 minutes...
Microsoft Guy: "Too bad, I'm transferring the caller now. You'd better have an answer." *Beep*

After telling me that he was unable to resolve the issue with Linksys (gee), he was going to transfer me to them. So they (also impossible to understand) Linksys lady tells me how she's going to walk me through all of the diagnostics.

Did the Microsoft guy even TELL her the problem!? After walking me through pointless stuff for another quarter hour (which I have memorized, I have called Linksys tech support about 20 times and their script is always the same) she instructs me to remove the WEP key.

"No, I want to keep my WEP key."
"Well, we can make WEP key short. Only 64-bits, less typing."
"No, I want a 128-bit one."

She basically tells me that she can't really do anything, and I thank her and hang up. After playing with the problem some more, it turns out that you don't get the error if you copy and paste into the dialog box. The whole ordeal took several hours. Oh, and I didn't get my trial Microsoft tech call back.

I'm not sure whether Microsoft CS people really don't know what they're doing, or if, when faced with a difficult problem they blame the first 3rd party vendor you mention.

Gah.

## I hate Hewlett-Packard's software.

Edit: I'm working on a logo which will not be used for a while,
so the ugly gray will be there.

Wondering where I've been? Well, probably not, but I'm going to tell you anyway. My computer has been completely borked. I don't mean borked like "OMG windows with boobies on them are popping up everywhere!!1," I mean borked like, "The file Hal.dll could not be found. Please insert the windows CD to re-copy this file and ensure stable operation of this computer."

The problem was, the only windows CD I had was the one that came with my computer five years ago was one of those Dell reinstallation CDs (you'd never know it was a Dell after all the part changing I've done to it, in fact, the only part that it still has in common is a stick of RAM). At one point I bought a new motherboard to install a 939 processor, and I used that Dell reinstall CD as a way to reinstall windows. Little did I know that OEM CDs can only be used on one hardware configuration. I ended up having to buy a new copy of windows (I didn't make the same mistake this time, and convinced my parents to get me a retail CD).

So why did "Hal.dll" get removed? Well, recently I got a new printer/scanner/copier/faxer, a Hewlett-Packard PSC 1410. It was really cheap, like seventy bucks from newegg. Well, in order to install it, you have to install at least 400MB of HP bloatware (the other option is 800MB) in order for the thing to function. I finally settled for the less bloated option, made sure to uncheck the "Install Special Features" button, and installed it. Upon install, the scanner wouldn't work. It just wouldn't. Like, I would click scan and a screen that said "HP Scanning" would appear, and then it would freeze that way. I found nothing about this on any forum online, so I decided to reinstall everything. Well, upon uninstallation some HP software engineer thought it would be a good idea to remove important windows files.

That wasn't the end of my trouble. After installing my new windows XP, I started having problems after two days. Windows would start, and then restart endlessly. Well, I thought that my power supply was getting old , so I conviced my dad to go to a local computer store (almost as cheap as newegg with no shipping, I'm going there all the time now) and let me buy a new power supply. The guy there quickly got me a nice new one that felt good and heavy. As soon as I got home and opened the case I noticed three swollen capacitors, which Asrock motherboards are notorious for.

A new motherboard, \$350 (100 for the mobo, 200 for windows, 50 for a PSU) and a fresh install later, I can now talk to you.

Ironically, the printer works now and is the best printer that I have ever owned.

## Engine status

It's been a long time since my last update.

My sprite engine is coming a long way, after a few months and many refactorings. After reading the book "Game Coding Complete, 2nd Edition." I decided to organize my engine like how the book recommends, which, incidentally is how the Microsoft Foundation Class is structured. Don't let that turn you off though, it's actually really cool.

There are three layers: the application layer, the view layer, and the logic layer. The application layer controls platform specific and engine global stuff, like file saving and loading, memory management, error logging, video surfaces, etc. The view layer controls input and output, lile the GUI, and the sound engine. The logic layer is where game calculations take place. Collision, physics, AI, and the process and state managers.

I'm spending most of my time right now getting the application layer up and working. When I'm done I'll update with all that I did.

## Memory Manager

As a result of my recent thread on creating a memory manager, I decided to create my own. I already know how I'm going to do garbage collection, it will involve a smart pointer class. I will post the source when it's done.

Currently, the client programmer can create memory pools of varying sizes (these sizes are all rounded up to the nearest kilobyte).

Here's an example of the pools working (and they actually work, a rarity for my code).

#include #include #include "Pool.h"using namespace std;using namespace stratus;using namespace memory;int main(int argc, char** argv){    try    {        //TEST: Make sure all implemented pool functions work        ////////////////////////////////////////////////////////////////////////////        //we want only 20 ints, but we get a Kilobyte worth        Pool<int> testPool("Test Integers.", 20);                 //create one integer        int* testInt = testPool.Allocate();        int* testInt2 = testPool.Allocate();        int* testInt3 = testPool.Allocate();                *testInt = 10;        *testInt2 = 20;        *testInt3 = 3005;                cout << "Value of int 1: " << *testInt << endl              << "Value of int 2: " << *testInt2 << endl             << "Value of int 3: " << *testInt3 << endl;                     cout << endl << "---------------------------------" << endl << endl;                     cout << "Total size in bytes: " << testPool.GetTotalSize() << endl;        cout << "Total free blocks: " << testPool.NumberOfFreeBlocks() << endl;        cout << "Total free bytes: " << testPool.NumberOfFreeBytes() << endl;        cout << "Largest Free Strip in Blocks: " <<                         testPool.GetLargestUnfragmentedBlockSize() << endl;        cout << "Largest Free Strip in Bytes: " <<                        testPool.GetLargestUnfragmentedByteSize() << endl;                        ////////////////////////////////////////////////////////////////////////////        //RESULT:SUCCESS                system("PAUSE");                return 0;    }        catch(const MemoryException& error)    {        cout << error.what() << endl;        system("PAUSE");                exit(1);    }}

this outputs:

Note that you have to name the memory pools. This is useful because whenever there is a memory error, it will throw the error as well as the pool that it happened in. Also, I plan on making a
"Memory Manager" class that will contain pools, and perform the garbage collection incrementally.

Also note that fragmentation is not an issue at all. The Allocate() function determines whether it is acceptable to allocate the memory at the end of the current strip or look from the beginning for a free block.

I don't like having to use Allocate so much, so I will make it to where other parts of my game engine allow you to just enter the name of the pool to use in their constructor.

## I got an XGameStation!

Hooray! I also bought the expansion set for making expansion cards, and a keyboard for it. Any suggestions as to what to add on to it? I'm going for another audio unit (three channels is not enough for me), another MPU, and 64 more kilobytes of RAM.

PS: If anyone is wondering about my game engine, it's steadily moving along.

## Update

Earlier today I had finished my stratus::Image class and file loader. Just now (12:05 AM) I have finished my bitmap to .inx (that 's the file extension) converter. Here is a screenshot of it:

It would have a preview window, but it doesn't because FLTK's image capabilities are teh sukc.

....

I'm tired.

## Update

I'm working on the main graphical component of my simple game engine. I also decided against using 256 colors, because I am not very good at creating a palette and it's a lot of trouble. I am still going to have pixelated graphics and vibrant colors though :) I think I am going to use 640 * 480 * 32 colorm, but only end up using a handful of colors.

I will update next when I get some screenshots, which shouldn't be too long from now.

## Update on 2D engine

Today I successfully used my new File Format. It's a paletted file format similar to an 8-bit .bmp file. Basically I added a name, creator, and description field, which can all be an undefined length, and I removed a lot of what was in the bitmap header. The palette is the same except that it's Big Endian. The data field is not written upside down, and there are no padded bytes on the ends of lines. There are also no size limitations (BMP forces an exponent of 2). Because of the slimmed-down header and lack of padding, my files are a bit smaller too.

The idea was to make a format that is easier for me to use, because it contains data fields that I need, and removes all of the extraneous ones from the .bmp format

The hardest part making this format was the loader. Upon loading my displayer kept seg-faulting. It turns out, the saver was saving data that was mis-aligned by just a few bytes, screwing up the whole file. I rewrote the saver, and now everything works perfectly.

Here is the file format:
    Image file:        extension -- .aibp -- Aerial Image Binary Paletted         --used to make sure it is loadable        float fileFormatVersion                 int sizeOfImageName        int sizeOfCreatorName        int sizeOfDescription                char imageName[sizeOfImageName]        char creatorName[sizeOfCreatorName]        char description[sizeOfDescription]                unsigned char bitsPerPixel        unsigned int width, height        unsigned int dataSize                --big endian, RGB, omit the  reserved member on save        SDL_Color palette[256]                Uint8 data[dataSize]

The reason I have the 'sizeof' fields instead of just null-terminating my name/creator/description strings, is because the fields make making a loader MUCH faster. I think the loading itself is faster too, because otherwise I would have to write a loop that looks at each byte to see if it's a null terminator. I think being able to be lazy is worth 12-bytes.

## Beginning my RPG project

NOTE: This journal is empty because I'm turning over a new leaf. I wasn't too impressed with my old stuff, as I intend for this journal to be somewhat of a portfolio with the occasional rant, and the old stuff was ugly.

If you missed the previous entries, I am working on a 2D role-playing game in the vein of Chrono Trigger. It will probably run in a 320 * 240 resolution with 8-bit color, for entirely stylistic reasons (I believe that less realistic graphics add imagination).

I'm programming the game engine now. The current part of it that I'm programming is the Image class. The image class is designed to wrap SDL_Surface* and add Saving, Loading, and Displaying. I have already created the savers. I also created my own uncompressed image format called .aipb .

I will update this with any progress.

## My 2D RPG engine

I have been working on the aformentioned 2D Role Playing Game, and all is well. I peeked into the Isometric and Tile Based Games articles section and found a good Tileset fileformat in an article by Dino Gambone that I shall use. It's working well.

I decided against using a 32-bit color mode. It seems wasteful because I'm using only 8-bit color (for effect). I'm going to make a simple pallette file loader once I'm finished with my tileset loader.

On a side note: does anyone know a good way to do animated tiles? I'm considering treating them like sprites, but then I can't layer them. If no one responds then I'll just make all of the animated tiles be on the base layer.

## w00t

This just in: I'm getting one of those awesome XGameStations for Christmas.

I know a lot of you don't like Andre Lamothe, don't ruin my fun please.

## Aerial Stratus

I have been working on my scripting engine, but ran into a few weird snags involving MinGW and its hateful Linker. Fruny and Programmer16 helped me get rid of those, so thanks!

I am thinking of how I might organize all of the components of this engine. I am leaning towards creating each as its own Dev-C++ project, and creating a library out of it. Then the final game engine will simply be these components. I may create a library that has linked in all of those others to form a nice, single uber library.

I have fallen in love with Dia (open-source replacement for Visio).
Expect more annoying diagrams .
Followers 0