Recent Changes - Search:

PmWiki

pmwiki.org

edit SideBar

Unit directory

Every unit in Boson has it's own directory under the units/ directory of a species. You can choose the name of the directory freely, but it's a tradition to prefix facility directories with fix_ and mobile directories with mob_ (except for neutral species), so the directory name might be e.g. fix_powerplant or mob_heavytank.
The unit directory contains several files specific to a unit:

Unit configuration file (index.unit)

This file contains configuration parameters which define e.g. unit's name, health, armor, weapons and much more.
See Unit configuration file specification for more details.

Model file (unit.3ds)

This is the model used to render the unit. It must be in 3DS format, although we might add support for other formats in the future.
The model should be in coordinate system where positive x-axis points to the right of the unit, positive y-axis points to the direction the unit is facing and positive z-axis points upwards.
See the modeling tips page for more information about creating models.

Overview images (overview-big.png and overview-small.png)

This are images of the unit, shown in commandframe (as overview or production button icons).
The -big file should be 100x100 and -small 50x50 pixels big.
Optionally, units may have overview pixmap for manual, named overview-manual.png and with size of 320x240 pixels.

Copyright note (model.copyright)

Contains copyright information about the used model.
Might look like this:

  
  [Copyright]
  Author=John Doe <foo@bar.net>
  License=GPL
  

Note that providing this file is not strictly necessary, it is needed only for legal purposes.

Additional files

Additionally, unit might use some other data, such as sounds, textures and effects. Those are not stored in the unit directory and not even in species directory (sounds are exception here).
The textures can be found in themes/textures/, effects in themes/effects/ and sounds in themes/species/*/sounds/ for all species and all units.
This is done to be able to share this data between all units. If you e.g. use textures that are already used by other units boson will use less memory (on runtime!) and might run faster (as texture memory is limited).

Edit - History - Print - Recent Changes - Search
Page last modified on October 20, 2005, at 16:27