GameTools tiled.xml

From Wikiid
Jump to: navigation, search

The file tiled.xml (in the 'data' directory) is only used by the 'tiled' program (not by the game itself), It lists the names of 3D model files which are to be displayed by 'tiled' - and also sets up the default grid parameters.

Example

Here is an example of a 'tiled.xml' file:

 <?xml version="1.0" ?>
 <tiled>
   <main placeGridXY="5.000000" placeGridZ="2.500000" showGridXY="1.0" >
     <model src="models/autotiles/tile_0000a.plb" bbox="-10.0 -10.0 0.0 10.0 10.0 10.0"/>
     <model src="models/autotiles/tile_0000b.plb" bbox="-10.0 -10.0 0.0 10.0 10.0 10.0"/>
   </main>
 </tiled>

Structure

Since this is an XML 'tiled' file, the first three lines must always be:

 <?xml version="1.0" ?>
 <tiled>
   <main placeGridXY="XXX" placeGridZ="XXX" showGridXY="XXX" >

...and the last two lines are always:

   </main>
 </tiled>

The <main ...> tag.

This line controls the grid sizes in the 'tiled' program.

 <main placeGridXY="XXX" placeGridZ="XXX" showGridXY="XXX" />
placeGridXY="XXX
Sets the X/Y 'placement' grid - ie at what spacing do positioned terrain tiles 'snap' to?
placeGridZ="XXX
Sets the vertical Z 'placement' grid - ie at what heights above zero do positioned terrain tiles 'snap' to (and, incidentally, how far does one tap on the 'PageUp' or 'PageDown' key move the model in the Z direction)?
showGridXY="XXX
Sets the size of the grid that tiled displays.

<model.../> records

Each model record contains:

 <model src="XXX" ... />

XXX is the name of the 3D model file.

You can add the following attributes:

bbox="x_min y_min z_min x_max y_max z_max
Sets the size of the bounding box of the object that 'tiled' will use to prevent objects from overlapping and to ensure that they are properly snapped to the grid. By default, it will calculate the bounding box of the objects being loaded automatically so you don't need this attribute. However, it is commonly the case that decoration items such as tree branches will stick a little over the edges of the tile and mess up this automatic calculation. Hence, you can override the position of the two opposite diagonal corners of that box with this command.


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