Post-Apocalyptic RPG forums

General Category => General Discussion => Topic started by: mvBarracuda on November 27, 2009, 02:05:34 PM



Title: Restructuring the objects directory
Post by: mvBarracuda on November 27, 2009, 02:05:34 PM
As I was unsure where to post it, as it tends to affect a couple of departments, I'll simply post it here.

Right now the structure of the objects directory in SVN is a bit confusing. Let me elaborate. The current structure is:
/objects
/objects/agents
/objects/buildings
/objects/flora
/objects/ground
/objects/objects

I've already started to restructure the directory a bit, e.g. by moving the walls from /objects/ground/walls to /objects/objects/walls, because /objects/ground should be really limited to ground tiles only.

Next stop: /objects/objects. The term object is actually defined in the FIFE map format specs, see:
http://wiki.fifengine.de/Map_Format#Object_File_Structure

Objects are basically prototypes of "things" or "entities" that reside on a map. Whenever you place an object on a map, it will automatically become a (map) instance (via definition). So I think we should stick with the object name for the top folder, because that's the name FIFE uses as well.

If we stick to the objects name for the top level directory, we should try to find a better term for the objects directory within trunk/game/objects. Right now a bunch of smaller "things" reside in there, e.g. walls, crates, barrels, beds, etc.

Any suggestion for a better name for this directory? E.g. objects/props? I appreciate every proposal.


Title: Re: Restructuring the objects directory
Post by: shevegen on November 27, 2009, 04:34:47 PM
I don't have a proposal but I must say that "objects/objects" sounds like a strange path. :D

The layout should make sense and be logical, and not confusing. From looking at it, I think "buildings"
is easy to understand, but what are agents, or what would be inside objects/objects?


Title: Re: Restructuring the objects directory
Post by: zenbitz on November 28, 2009, 03:40:53 AM
anything other than objects/objects

objects/props
objects/things
objects/stuff
objects/items
objects/scenery (maybe distinguish between "items" you can pick up / interact with and "scenery" which you cannot.


Title: Re: Restructuring the objects directory
Post by: mvBarracuda on November 28, 2009, 12:07:52 PM
I personally dig the idea of splitting objects/objects into objects/scenery and objects/items. Scenery for the items you (normally) can't pick up and move into your inventory. What do the others think?

@ shevy: objects/agents are moving objects, e.g. the player character. I think the term agent is used by FIFE so it makes sense to stick to it.


Title: Re: Restructuring the objects directory
Post by: shevegen on January 31, 2010, 02:12:18 AM
I am bumping this again, just to see what happens :D

Q_x started his object listing at the wiki. I wonder if we can fill in the wiki automatically somehow.



Title: Re: Restructuring the objects directory
Post by: zenbitz on January 31, 2010, 07:05:50 AM
Related to this, I d/l'd the portrait PNGs off of the wiki to incorporate them.   Of course, there is no autoscaling feature so they have to be scaled.  I can manage this it's a relatively trivial modification to the image_slicer.py script.

"Active" portraits (ie., scaled to roughly 100x100 px should go in gui/icons directory... but should we put the originals in SVN somewhere?  If so where?



Title: Re: Restructuring the objects directory
Post by: shevegen on January 31, 2010, 09:32:12 AM
I think we should.

How about:

portraits/scaled/
portraits/unscaled/


Although this is a bit long hmm.
portraits/original/


Title: Re: Restructuring the objects directory
Post by: Q_x on January 31, 2010, 04:43:18 PM
Maybe we should have all the source things in one big folder with its subfolders mimicking real game tree, so that someone can simply not download it while downloading whole game, and if one wishes to locate resource for pic XXX - he can do it in a simple way?

Barra, have we got shell access to our SVN? Is there a possibility of installing and batching all PNGs through some kind of shrinker? Or we must commit such changes in the normal way?


Title: Re: Restructuring the objects directory
Post by: mvBarracuda on February 01, 2010, 01:44:57 PM
No shell access to SVN. It sucks to commit things normally as it takes quite some time to do it for a large number of files but there's sadly no alternative to it.


Title: Re: Restructuring the objects directory
Post by: Q_x on February 01, 2010, 09:26:42 PM
We can do it in a time when shrinking would be needed, eg. near some major release. Lets just keep in mind - .PNG files are shrinkable without loosing quality.


Title: Re: Restructuring the objects directory
Post by: zenbitz on February 01, 2010, 10:05:14 PM
I wrote a python image scaler, it's in SVN now.

It's a little clunky in terms of file names (just takes the command-line input and appends "_scaled" before the extension), but it works.
If you have a unix/mac/cygwin  box you can just have it glob an entire directory of files.  I was thrown off by one of the portraits (quartermaster) being a jpg.

Before we decide on portraits, I guess we should figure out where other 2D in-game images should go (inventory ones, primarily)


Title: Re: Restructuring the objects directory
Post by: Q_x on February 02, 2010, 08:27:45 AM
But it is written! Its ImageMagick and it does wide variety of wizardry straight from commandline. And if you don't have Linux (as I'm happened to) - there is Adobe Photoshop with its fabulous batch.
.PNG shrinking I was writing about - most of it is altering compression and removing cruft from files. Pixels should be left untouched. I added it here: http://wiki.parpg.net/Post-techdemo_TODO#Graphics_Department - just to keep in mind