GameTools ultimate.xml

From Wikiid
Revision as of 19:43, 23 October 2007 by SteveBaker (Talk | contribs) (New page: The file 'ultimate.xml' is in the 'data' directory. It is the first file read by the game on startup and everything else comes from that. == Example == Here is an example of an 'ultimate...)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

The file 'ultimate.xml' is in the 'data' directory. It is the first file read by the game on startup and everything else comes from that.

Example

Here is an example of an 'ultimate.xml' file:

 <?xml version="1.0" ?>
 <game>
   <main>
     <camera id="0" name="Camera" fullscreen="true" />
     <model name="Hero"  src="models/characters/hero.plb" />
     <model name="Jeep"  src="models/vehicles/jeep.plb"
                         alt="models/vehicles/jeep_alternat.plb" />
     <model name="Tank"  src="models/vehicles/tank.ac"   />
   </main>
   <level name="The Training Level" src="data/training.xml" />
   <level name="The Volcano Level"  src="data/volcano.xml"  />
   <level name="The Arctic Level"   src="data/arctic.xml"   />
 </game>

Structure

Since this is an XML 'game' file, the first two lines must always be:

 <?xml version="1.0" ?>
 <game>

...and the last line is always:

 </game>

Between the <game> tags must be a section:

 <main>
    ...
 </main>

This section includes definitions for things that could be present anywhere the game - cameras, characters, moving vehicles, etc.

Then there are a number of sections that say:

 <level name="XXX" src="YYY" />

<level> sections.

There is one <level...> section for each level of the game. (XXX is the human-readable name of the level, YYY is the name of an XML level file that describes it. Currently, all levels can be reached from the startup screen - but eventually you'll be able to disable levels so they don't show up there until they are unlocked somehow.

The <main> section.

At a minimum, this must contain at least one camera and at least one model.

A camera record looks like this:

 <camera id="0" name="XXX" fullscreen="true" />

XXX is the name of the camera which must match the Java plugin that controls it - this is usually just "Camera". Currently there is just one camera (hence: id="0") and it's always set to be fullscreen="true".

A model record looks like this:

 <model name="XXX" src="YYY" alt="ZZZ" />

XXX is the human-readable name of the model - and also the root name for plugins/XXX.java and physics/XXX.xml which contain the behavior and physics of the model. YYY and ZZZ are model files in any format that PLIB knows how to load. The 'alt' (alternate) model is currently unused. (It was intended to be a greatly simplified model to be used for collision detection purposes - but this has been superceded by the physics file),


Wikiid Pages relating to gameTools (edit)
gameTools - Main page
gameTools - Support Tools :
plb_to_ac3d, mklevel, mktile, mktree, tiled, autogen_java, mk3dgallery
gameTools - File Formats :
title_screen.rgb, ultimate.xml, material.xml, decoration.xml, physics.xml
tiled.xml, tiled_autotiles.xml, Level files, Tile naming scheme, PLB files
gameTools - Source Code :
Game functions: gameCamera, gameClock, gameChecksum/gameHashTable, gameHTTP,
gameIsect, gameJoystick, gameParticleManager, gameScreen/gameMouse,
gameSky, gameStarter, gameStrokeFont, gameUtils
Material database: MatList/MatEntry
Tile map handling: TileObject/MapFlag/MapEntry/Map
Java Interfacing: JavaLink
Image file loading: liImage/liImageFactory
3D Model file loading: loadPLB, PLB exporter
Physics: Sabot, Bullet, gameTools - Use with Blender, PLB exporter
Object management: Object


Wikiid Pages relating to Lemur of Lima (edit)
Lemur of Lima - Main page
Lemur of Lima - Controls
Lemur of Lima - Levels :
List of Levels, Level design, Screen shots, Models
Lemur of Lima - Java Plugins :
Java plugin API, Event handling, Flags, GameInterface API , Alphabetical Index
Lemur of Lima - Source Code Documentation :
Initialisation, Main Loop, gameTools