Untitled Document


Hero Chess:

Nearing Completion
Polish
Mini Game Board
The Bishop
The Queen
Gibs
The Rooks' Attack Spell
The Rook
Blood
The Knight
Unit FSM and Camera Controls
Chess Framework

Research:

Phong #2
Phong #1
A Level Format
A Half-Life 1 .MDL Format
2D Rigid Bodies
2D Rigid Bodies
Reflection
Attenuation, Specular...
Materials, Planes...
Diffuse Light
Ray Tracing Framework
Pendulum
Ball Physics
Algorithmic Sphere
Verlet Integration
Rope Physics
Spring Equation
"Quick" Radiosity
Lightmapping (again)
Planar Triangle Splitting
Basic CSG Unions

High Level Shading Language (HLSL):

Z-Pass Stencil Shadows
Bump Mapping
Cel-Shading
Bump Mapping
SM1 Format
Cubemapping
First HLSL Shader

Gloom Engine:

Spell 2: Fire Projectiles
Spell 1: Spirit Summoning
Spell 3: Ice Projectiles
Spell 4: Lightning Strikes
Skeleton Mages
Screenshot #2
Screenshot #1
Triangulated Decals
CMF Format
Weather Effects
Console and Collision
Clouds
Lightmapped
Splatting
Framework and PWF Format

Level Formats and Algorithms:

MAP Format
Depth Biasing
Self Generated Lightmaps
Fun with Perlin Noise
3D Studio File Format (3DS)
Targetting Crosshair(s)
Beam/Electricity Effects
Sky Boxes
MD3 Models
AABB-Triangle Collision
Parametric Rays (math)
Planar Math
OctTree Implementation
The Quake 3 BSP Format
The Quake 3 BSP Format
Stencil Reflection

Beginner Projects:

Project Battle of the Twin Mages
Basic Decal and RPG Code
Project Athena
Battle For Mars, screenshot #2
Battle For Mars, screenshot #1
RAW File Format
Marble Drop, screenshot #2
Marble Drop, screenshot #1
Simple Particle Effect
Direct3D Pong
First Program!

 

[ Screenshots Blog ]

[2010][ 2009][ 2008][ 2007][ 2006][ 2005][2004]

 

Hero Chess

This game was an achievement of everything that I learned this year. I did not make any of the actual art or content, but I did program the game from scratch. It has many cool particle effects and the game turned out much better than I thought it would!


Late December, 2004 - Nearing Completion
Just need to make a few more adjustments with the AI and other things.

Late December, 2004 - Polish
The game is done! You can find it in the finished projects page!

Late December, 2004 - Mini Game Board
I decided to throw in a little 2D game board to make it easier to see where each unit is. The selector and possible moves will be added onto it later. The colors will soon be adjusted.

Late December, 2004 - The Bishop
They're sorcerers... oooh, what a surprise there =). I added flares on the tip of each staff just for fun. They cast lightning as their attack spell.

Late December, 2004 - The Queen
They're skeleton mages and can hurl fire or ice balls.

Late December, 2004 - Gibs
No comment.

Late December, 2004 - The Rooks' Attack Spell
Air starts to spin around the target like a tornado for about 2-3 seconds. Then, the unit plumits into a bloody death.

Late December, 2004 - The Rook
I couldn't find a castle, so these are air elementals.

Late December, 2004 - Blood
Kind of cool, splatters away from the melee slash and then sticks to the floor where they then disappear after several seconds. "Gibs" to be added later.

Late December, 2004 - The Knight
He throws his lance into the air and then charges when attacking another unit.

Late December, 2004 - Unit FSM and Camera Controls
FSM stands for finite state machine, and it's for the units (pieces) and it makes things so much easier. You know what I'm talking about... the make person go here in 2 seconds, then wait 1 second, and then play animation for 3 seconds scripting stuff. Yes, it's easy, but it can turn into a web of fugly code... simplicity > all.

Late December, 2004 - Chess Framework
Here is the game board until I add a wooden border. The squares are highlighted based on where the selected unit can move. The opposing team's pawns will always kneel in defense.

The green square selector used to be a beam of light, but I couldn't get it to look right.

Research


Mid December, 2004 - Phong #2
A second screenshot.

Mid December, 2004 - Phong #1
It's more or less the same as bump mapping, but should not be confused with "Phong Shading" which is completely different. I made it because I found this great site (below) that demonstrates the shader in a demo along with a PDF article. It's also where I got the textures of course. You'll have to understand the assembly-like code though.

Mid December, 2004 - A Level Format
(no larger screenshot)
The level format and parser which I primarily worked on from a previous dead project.

Mid December, 2004 - A Half-Life 1 .MDL Format
File loading gets easier and easier to code each time. The .MDL doesn't even have any documentation though, so I had to learn from the SDK source code. I had to learn a little OpenGL in order to understand what the hell was going on.

Mid November, 2004 - 2D Rigid Bodies
Both linear and rotational forces acting on a rigid body using quaternions. I will only support cubes for now because it makes calculating the moment of inertia so much easier. If it's wrapped around a complex object such as a statue, then no one will know the difference anyways. There is only lite collision support.

Mid November, 2004 - 2D Rigid Bodies
I store the angles and manually rotate the points with trig each frame, rather than integrating the points which causes the shape to bulge.

Early November, 2004 - Reflection
(no larger screenshot)
This was thrown into an infinite loop the first time I tested it out, lol.

In the image on the left, there is a max of 3 rays, including the initial one. The floor is also reflecting. Nothing is reflecting by more than 70%.

Early November, 2004 - Attenuation, Specular...
(no larger screenshot)
ugly

Early November, 2004 - Materials, Planes...
(no larger screenshot)
boring

Early November, 2004 - Diffuse Light
(no larger screenshot)
It worked on the first attempt which was surprising.

Early November, 2004 - Ray Tracing Framework
(no larger screenshot)
Ray Tracing Framework and the BMP format. Here is my first ray traced image. To the right is my console dialog box that just displays text and stuff. The images are manually saved as .bmp (not using any third party libraries or win32).

Mid October, 2004 - Pendulum
(no larger screenshot)
No comment.

Early October, 2004 - Ball Physics
(no larger screenshot)
The balls bounce and respawn when they fall off. They do not collide against each other.

Early October, 2004 - Algorithmic Sphere
(no larger screenshot)
Not that is makes any difference on how I create the actual spheres, but I just like the idea of creating things through math and code.

Early October, 2004 - Verlet Integration
(no larger screenshot)
Verlet > Euler ...not that I think so, it's what I've been told.

Early October, 2004 - Rope Physics
(no larger screenshot)
If you attach many springs together (nodes) you get a rope! You can also apply gravity and mess around with the stiffness to make it even more realistic. It's great giving just a few instructions and watching how much it can affect things.

Early October, 2004 - Spring Equation
(no larger screenshot)
It's a line!... actually it's a visual representation of a spring with mass applied to the top. It bounces.

Late September, 2004 - "Quick" Radiosity
(no larger screenshot)
The light source is white, reflectance is blue just to show how light can bleed around corners. This is mostly hacked in order to save computation time, but it still takes a very looonngg time, especially with multiple passes! I'm going to use ambience and normal lightmaps with attenuation equations instead. I heard you can do all this in a pixel shader, but I'd rather have preprocessed maps for static environments... for now.

Late September, 2004 - Lightmapping (again)
(no larger screenshot)
I've done this before I know, but now I have a very firm grip on it. This is of course a prerequisite for radiosity - adding initial light sources until everything begins to scatter and smoothen through multiple passes.

Once again using planar projection, except with the idea of "major, baseline, and range" for the xyz elements.

Late September, 2004 - Planar Triangle Splitting
(no larger screenshot)
The data is from a .MAP file.

Late September, 2004 - Basic CSG Unions
(no larger screenshot)
This, is hard. The theory is really simple, easy to imagine, but the implementation quickly populates with bugs dealing with floating-point inaccuracy, coplanar triangles, duplicates in some areas, and triangle to plane relations. These were all fixable and it now works. The point of this was to rid triangles within other brushes through splitting, but it now needs to rid triangles on the exterior of the world... I'll come back to this.

High Level Shading Language (HLSL)

I began learning the Direct3D language for shaders. A lot can be done with just so little code! I worked primarily with shader model 1.1 and 2.0.


Mid September, 2004 - Z-Pass Stencil Shadows
(no larger screenshot)
Finding the contour edges on any model from the light source was also clever, definitly something to remember. How this is all set up, encourages indexed triangles; so that's another good thing...
will work on z-fail and shadow capping when I have a use for this algorithm in a large project, but that will probably be in a long time from now.

Mid September, 2004 - Bump Mapping
(no larger screenshot)
In tangent space, rather than object space as shown previously. One of the techniques with the highest eye-candy output per lines of code ratio.

Mid September, 2004 - Cel-Shading
(no larger screenshot)
Cel-Shading without outlines. I did this out of curiosity on how the effect is achieved. In a way, it's no different than any other lighting technique, except it uses a lookup table, that's about it. I'm not going to bother doing ink outlines or any fancy stuff because I don't plan on doing this in particular effect, ever again.

Mid September, 2004 - Bump Mapping
(no larger screenshot)
Done in object space so it is very easy, unless you want to generate the normal map yourself. I realized that this effect involves way too much tweaking to get just right.

Mid September, 2004 - SM1 Format
(no larger screenshot)
SM1 stands for static model 1, it trashes a lot of the original 3DS format contents which cuts the size in half. I did it just to do it.

Mid September, 2004 - Cubemapping
(no larger screenshot)
The cubemap is one of the easiest effects to achieve with shading - it uses very little math, but still looks pretty cool.

Mid September, 2004 - First HLSL Shader
(no larger screenshot)
Initially, I used NVIDIA's effect edit, but it kept crashing so I used RenderMonkey instead. So far it's been pretty easy; everything makes sense, except the cryptic assembly code which I won't learn for now.

Gloom Engine

The idea was to create a straight forward engine for my own use. It was outdoor based and featured "infinite" terrain (tiled through procedural heightmaps). The actual game built on top was not planned out to any great extent.


Mid September, 2004 - Spell 2: Fire Projectiles
(no larger screenshot)
I wanted the game to be a little fair, so the height is fixed to the terrain. It was initially thrown at a direction towards each target, but the fireballs would usually explode on the small hills, very frustrating!

Mid September, 2004 - Spell 1: Spirit Summoning
(no larger screenshot)
They were supposed to look like spirits, or at least a little bigger. It's an innate spell which uses the space bar, instead of a number key and its purpose is to target surrouding monsters in order to cast a fireball or any form of projectile. This will be considered your "mana" which limits how often you can cast damaging spells... seems to be annoying rather than a cool feature of the game.

Early September, 2004 - Spell 3: Ice Projectiles
(no larger screenshot)
They do little damage directly and deal no radius damage at all. Mainly, they're used to slow down fast little goblins by freezing them...
Right now I feel a lot like how I did in the past, getting to the point where I'm no longer learning anything new. Just, changing variables around and adding new similar functions. It's so unmotivating.. and boring too.

Early September, 2004 - Spell 4: Lightning Strikes
(no larger screenshot)
These bolts of lightning can deliver either very little damage, or enough to kill a monster in a single blow. Unfortunately, you spin around while casting which leaves you vulnerable for a split second.

Early September, 2004 - Skeleton Mages
(no larger screenshot)
These guys have the ability to revive fallen goblins. The mages have twice the hp as an ordinary goblin, but revive for very few so this'll hopefully make the game more fast paced. Probably, I'll have clans spawn whenever necessary behind the player after the current clan has fallen the skeletal leader dies, then have the remaining goblins and corpses disappear in a few smoke puffs.

Late August, 2004 - Screenshot #2
This uses snow textures instead. The AI is surprisingly decent, the goblins (and future melee/mage skeletons) go around eachother and use their little weapons to try and kill you. So evil, don't you think?

Late August, 2004 - Screenshot #1
A screenshot of the project so far.

Late August, 2004 - Triangulated Decals
(no larger screenshot)
This was difficult because I was batching all the decal textures in order to reduce expensive render calls. It all worked out, but I'm really unhappy with the code so I'll rewrite it all tommorow. It supports dynamic and static decals. Static is created once, will not move, and is perfectly aligned to the terrain's triangles. Dynamic uses more triangles (can be off a few unnoticeable pixels) and can move around such as player shadows, while updating only when needed.

Mid August, 2004 - CMF Format
(no larger screenshot)
CMF Format - converted model format. I started to write little console app converters to strip away a lot of garbage from each type of model and compile them into my own format. I hate having to use a commercial file format meant for another game. Everything is also nicely bumped up onto a fixed height and rotated for left handed coordinates. This has now opened up the branch into AI - something I have never done before :(

Mid August, 2004 - Weather Effects
(no larger screenshot)
I built the effects right into level format itself for obvious reasons. The screenshot is so small that you cannot see any of the snowflakes, but they look decent as they blow in the wind. There was also flying debris to simulate a blizzard like effect and sand kickup, but I removed it because I couldn't get it look right, especially with the ground cutting it off unless I raise it higher off up. It'll remain an option with a certain console command, off by default removed it completely!

Mid August, 2004 - Console and Collision
(no larger screenshot)
Nothing special, just a console like any other game out there. It'll help me debug and call internal functions whenever I want. The texture is just something I found on the internet. I'll end up replacing it with a grayscale image then alpha blend it in blue for a few shits and giggles... but it's not that important. As for the collision detection, it uses the heightmap to bump up anything while gravity pulls it down. It uses three lerps from the four height values, making it both extremely fast and smooth.

Mid August, 2004 - Clouds
(no larger screenshot)
These few cloud layers are also generated when loading the level and move with the wind. It'll take some tweaking for them to look better. I also used a better skybox to have a smooth transition at the drop off point (max distance you can see) so they both turn black at the end to avoid the popping effect of the terrain. Nvidia were the ones who gave away these free textures.

Mid August, 2004 - Lightmapped
(no larger screenshot)
Fortunately, the terrain no longer looks like vomit =) I implemented a lightmap generator by using a reference heightmap, by iterating and checking the height in a specific direction using a lite version of Bresenham's Algorithm I read about. I was forced to multitexture it with the lightmap, but surely the speed decrease won't be bad at all.

Mid August, 2004 - Splatting
(no larger screenshot)
After generating the main texture with a few layers, I realized that splatting makes the terrain look in the most part, fake. These textures aren't very pretty either. As for the terrain itself, it is now very smooth, and goes on forever - only limited by floating point ranges, but will not be an issue.

Early August, 2004 - Framework and PWF Format
(no larger screenshot)
In the past days, I created a window with a dialog for all possible settings to run release mode in (I hate windows programming). My pwf format gives instructions on generating a procedural heightmap as well as the splats needed for the main texture to avoid multitexturing each frame (not fully working yet). So no, it's not actually infinite terrain, however updates the buffer when the distance from previous update is greater enough compared to max view distance - allowing good performance.

Level Formats and Algorithms


Early August, 2004 - MAP Format
(no larger screenshot)
The problem with this format is the fact that it does not store any points or triangles, only planes that make up polygons. No problem, just find the intersection of three planes for every combination and make points out of them and all will be well, right? No, when it comes time to building triangles out of them, they won't be indexed correctly, instead I projected them onto one of the three planes and used tricky use of the values to properly build a fan-like triangle list. It worked for me!

Early August, 2004 - Depth Biasing
(no larger screenshot)
Back then I didn't even understand the stencil buffer, but I now realize how to properly make things such as decals and shadows. It's good to get these minor little issues out of the way, especially if you leave it to the API to do all the actual work :)

Late July, 2004 - Self Generated Lightmaps
(no larger screenshot)
This was difficult to implement, and isn't even flexible. First, I had an incorrect ray formula. Second, my crossproducts were off. Third, lightmapping isn't easy to begin with until you clearly know what you're doing, so in this case took a while - until I had the equations for planar projection. The screenshot doesn't look like much, but the upper quad is blocking light which causes a pitch black shadow on the bottom surface.

Mid July, 2004 - Fun with Perlin Noise
(no larger screenshot)
This fluffy clouds image is generated using perlin noise with exponential smoothing along with blurring to make them look more fluffy. It is also very seamless, which was what I was aiming for.

With this generator, I plan on making infinite terrain (looping) and all sorts of cool looking clouds. The image was scaled down and cut off, so don't get expect it to tile correctly.

Early July, 2004 - 3D Studio File Format (3DS)
(no larger screenshot)
This file was very easy to open thanks to wotsit.org for documenting almost every detail on the format. However, I only loaded the necessary data, skipping more than half of it (that's why it's rendered in wireframe). I don't plan on ever using this format, instead I will write my own format and extract the minimal data from each model into mine accordingly with the artists' consent.

Early July, 2004 - Targetting Crosshair(s)
(no larger screenshot)
I got the idea from the game Alice - constructing the crosshair where each is made up of a particle effect. A ray is casted onto the world for the closest triangle (or intersection of a monster's bounding sphere/box). When targetting, it then splits apart and spins around the target, though hard to see in the screenshot. It's fun to see code work as it should!

Early July, 2004 - Beam/Electricity Effects
(no larger screenshot)
I had always attempted to conceive of a technique to make semi realistic electricity or beams of some form of pulsing energy. I found that the most simple method can be the most convincing. This beam is simply two tinted grayscale textures that move, making this single strand appear animated.

Late June, 2004 - Sky Boxes
(no larger screenshot)
Okay, not the most interesting thing in the world. It is a skybox rendered without depth, surrounding the player by rendering it first at a constant (small) unit length. Everything is then rendered right on top of it to make it look like it's far away. As a result of it being rendered first, it has a high fill rate of which I really don't care about. The fill rate can be reduced by rendering it last.

Late June, 2004 - MD3 Models
(no larger screenshot)
MD3 models weren't too bad, I just needed a wider selection to choose from. When I got done learning how to import it and parse my own cfg files, it seems that there aren't as many models to choose from, online! The loader right now isn't very reliable, no error detection on external cfg files, though will work everytime if everything is as it should be.

Mid June, 2004 - AABB-Triangle Collision
(no larger screenshot)
This was initially some minigame that I was making, but the whole plot to the game was too weird. Allowing a player to run around a room without falling through the floor is more difficult than I thought it would be. I'm glad that I got it to finally work.

Early June, 2004 - Parametric Rays (math)
(no larger screenshot)
It's really easy, really quick, and has so many uses. Enough said.

Early June, 2004 - Planar Math
(no larger screenshot)
This was initially another turn based RPG, but I decided not to make it after all. Instead I used it for other testing purposes. The particle effect turns a different color if its emitter is under the planar surface using fairly simple math.

Early June, 2004 - OctTree Implementation
(no larger screenshot)
I decided to implement an octtree (however you spell it) to help cull out large portions of a map for experimental purposes such as its use with terrain. Not to meantion it's just a cool thought on partitioning a world that way, especially if it's a huge section of terrain. I realize that it's faster to just render everything in this small scene than to cull portions out.

Late May, 2004 - The Quake 3 BSP Format
(no larger screenshot)
A second screenshot.

Late May, 2004 - The Quake 3 BSP Format
(no larger screenshot)
This had some of the nastiest bugs I've ever had to fix. The frustum culling took longer than I thought it would, since I had to learn all the math related topics mentioned above from certain forum posts. One day ago, I used the two maps on the left I made for test purposes.. because of the number of bugs, I never wanted to see them again. However, now that the frustum culling actually works as it should, I've never been happier to run through those two bad maps.

The next step is to make an octtree and use collision detection now which shouldn't be too bad. I realize how the bsp tree is structured to avoid doing the tests in the first place, but I wanted to know how anyways.

Late April, 2004 - Stencil Reflection
(no larger screenshot)
The version that I made has the mirror rendered last after all the geometry is translated as a reflection, and then render the mirror with an alpha defined in the diffuse property.

Beginner Projects

All the projects and work I did while learning C++ and DirectX9! At the time of creating these, I was doing it out of curiosity. I had no idea that I'd continue for many years to come.


Early April, 2004 - Project Battle of the Twin Mages
(no larger screenshot)
A turn based RPG! Every file loaded into the game is placed into a manager and the spell system in the battle state features really cool particle effects to go with them (auras, projectiles, shields, etc). This was the first time I used heavy use of pointers, vectors, and linked lists. I feel very confident using them now.

Early April, 2004 - Basic Decal and RPG Code
(no larger screenshot)
This screenshot shows a decal being applied to an even surface. It's nothing more than an alpha-blended quad with a color that spins which I think looks cool.

Late March, 2004 - Project Athena
(no larger screenshot)
This was the first time I have ever programmed near completely with OOP and most definitly learned better game architecture. The past month, I have managed to learn the MD2 file format and the basics of DirectMusic and DirectShow. She had some working weapons that kill animated monsters through a few maps that were loaded from text files.

Late Feburary, 2004 - Battle For Mars, screenshot #2
(no larger screenshot)
A second screenshot.

Late Feburary, 2004 - Battle For Mars, screenshot #1
(no larger screenshot)
The particle engine was a success and I managed to construct enemy members that fire projectiles. I also had to learn how to use a different flexibile vertex format (FVF) to blit 2D quads on the screen.

Early Feburary, 2004 - RAW File Format
(no larger screenshot)
I now understand the basics of loading .raw files and displaying the color values in 3D form. This format makes it so easy it loop through each byte and copy its color data into an integer/float array. This will be my format for simple terrain.

Late January, 2004 - Marble Drop, screenshot #2
(no larger screenshot)
A second screenshot.

Late January, 2004 - Marble Drop, screenshot #1
(no larger screenshot)
The project took one day in planning, where in my spare time, I wrote all the necessary game plans and potential "pitfalls". It then took two days to complete the artwork and fully code using my personal base code. The marble in the game is just a blue sphere, I had problems texturing it with something more realistic other than a blue blob in the middle of the screen. The arrow keys control the velocity of it with time based movement and makes use of very lite use of collision detection to test if it's within the boundries, or outside. This project wasn't too hard, learned a few things I was doing wrong in the past too.

Mid January, 2004 - Simple Particle Effect
(no larger screenshot)
One of the best things about video games, are the particle effects. I skipped ahead and managed to build a simple particle effect that explodes from the origin. Each triangle always faces the camera with the use of the billboarding technique.

Early January, 2004 - Direct3D Pong
(no larger screenshot)
This was a project I decided to program while learning Direct3D vertex buffers, matrices, and other topics. As part of the celebration of a new year, I've begun studying DirectX.

Early January, 2004 - First Program!
(no larger screenshot)
This is one of my first programs ever - done completely in C and built as a console application. The code is messy and there's use of certain repetitive code. It is actually just a simple turned based text-based-game where the player battles against a dragon in text mode. There are no items, but there are four magical spells. This project has been lost forever.

 

 

 

www.elliotpace.com