Sunday, March 17, 2013

I Find Git Very Annoying

So I've generally been working with Bitbucket and Mercurial.  Everything has been happy and working well.

But lately I've done some experimental work with Azure, and also decided to clone Monogame from GitHub.  I'm taking Monogame and making some additions so that you can load XNA Models server side.  The changes will allow you to load a model without the textures, vertex/index buffers and effects.  Which also means you don't need a graphics device.  This will let me load the model and bones server side (which is likely headless) for per-triangle hit accuracy even with animation.

Anyway, so I clone Monogame to Bitbucket.  Fine.  I then clone the repository locally.  I tried making may changes and pushing, but got an error.  Essentially the remote repository was ahead of my local (which I had JUST pulled).  Eeeeeh?

Well, it seems like what is happening is that when I clone the repository it is taking from the Develop branch.. but when I try to push it is pushing to the Master.

You'd think that would be easy to change, but no... it's probably somewhere in some arcane command line option that I'll have to dig to find.

Anyway, it doesn't just work like Mercurial has been doing.  I'm sure I can dig to make it work... but this is my first encounter with Git, and it has thusfar failed completely to do something VERY EASY.

I didn't know anything about Git previously, but I think I'll avoid it from now on if practical.  Pull->Change one line->Commit->Push ought to just work.

Edit:  I wasn't able to figure out how to do this from the command line or Git GUI.  But GitHub for Windows allowed me to easily switch the operating branch.  Twenty seconds there and I was done.  Thanks, Git.

Tuesday, February 19, 2013

A Context Menu

As I'm getting more and more things added into the engine, interacting with all the objects in the scene has gotten more complicated.  Also I'd like to start working toward an actual game-like interface as opposed to my cheesy test interface.

Besides all the debug-type side buttons, you could take control of any of the entities in the scene by double-clicking on them.  This allowed you to pilot them with the arrow keys (a bit cumbersome, but fine for testing physics/collisions/rendering).  A single click would select an object, highlighting it.

Thursday, February 14, 2013

Forward Rendering and Transparency

After quite a lot of work into the wee hours last night I now have the Forward Rendering pipeline set up.  When an entity is created it can be given a RenderBehavior of Full, DeferredOnly or ForwardOnly.

'Full' entities are rendered via the Deferred rendering step.  They are also active in the Forward rendering step, but the entities themselves are not drawn, just (if activated) associated primitives such as bounding boxes, debug info, etc.

DeferredOnly entities are rendered via the Deferred step, and completely excluded from the Forward step.  Vice versa, ForwardOnly entities are rendered via the Forward step and completely ignored during Deferred processing.

The is one complication I do need to deal with:  an entity that is party transparent, but has non-transparent parts needs to render in both the Deferred (non-transparent parts) and Forward (only the transparent parts). I need to sort that out properly.

Cloud layer is transparent and Forward rendered.

Specular and Normal Mapping

I've finally gotten around to re-adding specular and normal (bump) mapping.  Project Vanquish, the framework I began from, implemented these.

Early on since I quite frankly had no idea what I was doing, I disabled a lot of things for simplicity.  Specular and normal mapping were among the first things to go in the Great Renderer Simplification.  They've now returned, and look quite nice!

Shiny!

Tuesday, February 12, 2013

Restoring Depth

I've been refactoring some of the drawing code in the Rogue Moon game engine.  I've had nice bounding box drawing working and in the same manner wanted to add some sort of 'engine trail' effect.  I got this working, but then decided that both of these needed to move to a 'post process' step.

Tuesday, February 5, 2013

Game Engine Part 2

As I said in the last post:

I'd been mulling the engine design over in my head while working on the graphics engine.  I wanted, above all, to make it easily extensible and cleanly separated from the rendering engine.  After all, Rogue Moon is to be an online client-server game.

Then I got off onto the tangent about game networking.  But it did have a direction.  If you followed that post, you may have realized that modern latency-compensating online games require two simultaneous (yes, I know I said simultaneity largely goes out the window) simulations, client and server.

Monday, February 4, 2013

A Game Engine

So, it's been a while since I made a post; Christmas and the like interfered a bit.  But I have done quite a lot of work.

For now the shadows and rendering engine are 'good enough', so I've moved on to the meat of the game engine, as it were.

I'd been mulling the engine design over in my head while working on the graphics engine.  I wanted, above all, to make it easily extensible and cleanly separated from the rendering engine.  After all, Rogue Moon is to be an online client-server game.

Edit:  this turned into a post about networking and game engines, not where I initially meant to go.  But I'm going with it...