Jump to content
  • Advertisement
  • entries
    28
  • comments
    53
  • views
    19086

About this blog

A Hobby Programmer's Rants

Entries in this blog

 

Week of Awesome III - Part #1

So the theme is "Death is useful". This actually matches an idea I had quite a time ago but never realised as game.

It boils down to a simple 3d puzzle jump'n'run, where you as the player get several lives to complete a mission. If you die your body may help or hinder you in your task. E.g. jump on spikes, die, new live can now jump on the body and continue on.

I hope to get some nice ideas on how to kill the player in useful ways


On the graphic representation: I used the flat 3d view before in a Ludum Dare game and it's ideal for this kind of game. Also, it's quite easy mathematically


Also, here's a picture of a hastily pixelled bunny as the player!



Endurion

Endurion

 

Week of Awesome III coming up

In the later times I've come to write more and more games for C64 and my PC development got less and less. I do love me my little peaks in the form of competitions, like Ludum Dare, or GameDev's Week of Awesome.

How to prepare?
Decide which engine/libraries to use. Usually you have your favourite library about, but do you still remember all the little details? Maybe some base code changed and things don't work out of the box anymore?

Set up an empty project that opens up a window and sets up everything. Run it and be ready...


Interested? The competition thread is over here: https://www.gamedev.net/topic/668847-the-week-of-awesome-iii-the-third-annual-unofficial-gamedevnet-competition-administration-thread/

Endurion

Endurion

 

Asset Studio - Asset Management Tool

After years and more years of manually adding new assets into code I tried a newer approach. I'll use this journal entry to show off my asset
management tool (Asset Studio) but also ask for similar stories.


When I use the word 'asset' I mean images/textures, image/texture sections, fonts, animations, sounds, meshes, GUI dialogs, text tables, value tables, key/value tables, 2d layered free section and tile maps with objects.

In the days of yore (think DOS with Turbo Pascal 3) I added assets in code directly. There were no asset classes, or a manager. Only bits, and even the zeroes were... ahem.

In later days assets were handled classes, external files and complicated to handle. There are images, sounds, text tables, GUI dialogs. You name it. When tackling bigger games I stumbled again and again over the problem, that I wanted to reference other asset types, but couldn't, as they were stored in different files. There were different editor executables which didn't know anything about the other types.

The final solution was to add a asset file, that kept crucial information in one place. This was stored in XML. There were still external files for more complex assets (you really don't want to put a texture in an XML file). And to manage all assets I wrote an asset manager, namely Asset Studio.
This tools incorporates the whole asset type range and even has editors for the simpler assets.
Assets are referenced by name, so both asset type and name combined must be unique.



I used Asset Studio extensively for my Week of Awesome II entry "Building Blocks" (Post Mortem here: https://www.gamedev.net/blog/949/entry-2260318-the-week-of-awesome-ii-post-mortem/)


I'm pretty happy to finally have inter asset type references. I can see the chosen font and images in GUI dialogs, have text tables as source for GUI components, key/value tables as object templates for 2d maps, etc.

The underlying code is not really that clean IMHO but clean enough for now (TM). I do have a base class that stores the type specific asset info. Since my game framework is plugin based, and some assets are plugin specific, there is no real single location to load assets. Basic assets (text tables, GUI dialogs) are loaded by the framework itself, other assets (textures) are loaded by the relevant plugin on "loadup".

Practical problems I'm aware of are:
* Asset lookup is string based, not the fastest
* Theoretically plugins can be switched at runtime, this could lead to errornous asset caching (if I wanted to avoid string lookup). Probably the reason why I do not switch plugins at runtime
* Normal Asset types appear at level 2 of the XML hierarchy. Only exception are GUI dialogs, they allow nesting.

Wishlist:
* Prepare binary asset package file

So, how did you approach assets?

Endurion

Endurion

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!