Pages

Tuesday, June 26, 2012

Sky

So, considering the last post, Terrain, one of the other constantly visible things in a game is the sky. Whether  you're just getting a glimpse of it as you fight off some monsters or flying through it, the sky can be equally important as any other part visual part of a game. so of course I've gone ahead and started work on the sky system for Ruined. I wanted to follow the art style of the game, so I stuck with a stylized design.
The sky is still "under construction," but I feel like a good portion of it is working



The clouds follow the stylized theme of the game,
and move dynamically over time



Friday, June 22, 2012

Terrain

One of the most important things in a game can easily be its terrain. The scale, the detail and the atmosphere it creates easily make a good terrain system a must.

So of course I've begun work on a terrain system, nothing fancy yet, I've only invested 2 days in it so far, but I'm pretty pleased with the results.

I've created a terrain editor, built right into the engine.
Features include:

  • Loading/Saving of a height-map
  • Physics, dynamic lighting... - all the features of the engine
  • Texture splatting
  • Raise, lower and smooth tools
  • The ability to paint terrain from right in the game!
I still need to look at some optimization techniques so I can be sure it runs flawlessly on the Xbox, but for now here's some screen-shots of the editor.

The terrain editor doing its thing.
Green = Raise; Red = Lower; Blue = Smooth; White = Texture Paint

Tuesday, June 19, 2012

Back and ready for action

So as the title says, I'm back! "From where?" you may ask;
I had had finals and afterward was taking a quick brake/vacation for the summer, but I assure you I'm ready to get back to work now.

A few new features have been added that still need to be tweaked before I can show them off, namely a couple of render-specific adjustments. All will be revealed shortly...

Thursday, May 10, 2012

Nav-Mesh Editor Part-3

Okay, making more progress on nav-meshes!
New features:
  • Polygon Select Mode
  • Automatic neighbor calculating
  • Path finding preview
  • Nav-Mesh file format ( *.rnm)
I made some more additions to the editor, mostly to make creating these meshes easier. I had to do all the work associated with making a model editor, except my "polygons" can have up to 15 sides ( expandable to 18). All of the navigation data is stored in the one of  the most memory-efficient way possible IMO.

I also got around to making a file-format to store the navigation-meshes in! I call it "Ruined Navigation Mesh" format - original and ironic I know. These files are also VERY size efficient.
For all of you out there familiar with XNA, I've written my own importer and processor...

Ruined-Navigation-Mesh-Format:

Offset
Description
Size
0x00
Header "rNavMesh"
8 bytes
0x08
Number of Vertices (v)
2 bytes (ushort)
0x0A
Number of Polygons (p)
2 bytes (ushort)
0x0C
Vertices
12 bytes (float3) * p
0x0C * v * 12
Polygons -
xp vertices ( ushort[] )
yp neighbors ( ushort[] )
Sp = Sp-1 + 4 + xp + yp

Data stored in memory as a single ushort[]

One of the great things about just reading data directly from the file is that XNA can compress *.rnm files automatically!

So in other words, all that's left to do with this is to actually make the meshes, and program some AI to use them :P

Path-finding, Initial Polygons 
Path-finding, Found Path 




Note : Polygons are stored as a single ushort[] in memory, the actual polygon's data is extracted from this array (Yay! bit-wize Shifts)

Sunday, April 29, 2012

Nav-Mesh Editor Part-2

So, as usual I have very little time to work; the time I am getting though, I am using to make sure I can better use my time.
Hence why I've spent more time on the nav-mesh editor.

Additions:

  • A translation tool (similar to most 3d editors).
  • Polygon highlighting.
  • Usability tweaks.

Anyways here are some pics to show what I'm talking about:

The navigation-mesh mesh editor.






Sunday, April 22, 2012

Nav-Mesh Editor

So as I mentioned in the previous post, making navigation meshes on pieces of paper is a pain. So I've created an editor that runs right within the game.
Don't worry, this won't show up while you're playing :)

Anyways, I can now make the nav-meshes much more easily, which should help speed up level creation!

What works:
  • Multi-selection of vertices
  • Keyboard based tranforms
  • Adding new vertices
  • The display of vertices (boxes)
  • The mesh visual, cyan outline of polygons

What's still missing:
  • Selecting polygons
  • Creating new polygons

So hopefully, when those last few features are added, I can create and test out a level that implements the navigation system...

 

Friday, April 13, 2012

Navigation

So, I've reached the awfully wonderful part of a game's development, where you have weapons programmed and tested, but now, you are just dying to get something to hit in your game.
This means AI is coming up fast!

Okay, so almost any game with an AI system needs to implement some sort of navigation system.

And that's what I've been working on for the past few days.
I have created a Navigation Mesh system for Ruined, that's powered by the A* ( A-Star ) navigation algorithm


You can read up on what exactly a Navigation Mesh is at any of these links:
Then you can learn about A* and its implantation at any of these:

Anyways, the gist of this all is that the monsters and enemies in Ruined should be smart enough to find you and KILL you, no matter where you hide :P

The test navigation mesh, with a test path. Red = path

The test mesh was created by hand, on a piece of graph paper.
The test path is from cells A to P.
So, I still need to devise a way to actually make these Navigation Meshes, because doing them all on paper would be RIDICULOUS, but for the most part, I've managed to get one step closer to finishing the game!