Actions

Dat Format: Difference between revisions

From Populous Wiki

mNo edit summary
Line 9: Line 9:
==Objects==
==Objects==


The object data starts at 0x14043 and carries on for the rest of the file. Each object is 55 bytes containing all the object's information. Most of the block is not used. The next object starts after the first object and so on. Having more than 2000 objects will slow the game down too much and will be unplayable.
The object data starts at 0x14043 and carries on for the rest of the file. Each object is 55 bytes containing all the object's information. Most of the block is not used. The next object starts after the first object and so on. The total number of objects should be less than 2000.


===General Object Data===
For more information visit [[Object Data]]
 
The first two bytes determine which object it is. The first byte represents which object in the category and the second byte is the object category. Read [[Object Data]] for a list of objects and their information.
 
The third byte represents which tribe the object belongs too. (FF is wild) (AA is also wild).
 
The fith and sixth bytes is an integer representing the x-axis of where the object is located.
The seventh and eigth bytes is an integer representing the y-axis of where the object is located.
 
The ninth byte is the orientation of the object. (0 to 8 directions)
 
Triggers, Effects etc. have additional data. For more information visit [[Object Data]]

Revision as of 05:39, 10 December 2009

Dat files are stored in the levels directory and contain the land structure and all the initial objects. These are kept in two blocks of data.

Land Structure

The land data starts at 0x0. Each point of land is a word/shortinteger one after the other. 0 is the lowest point which is water. 1028 is consided to be the highest as braves lower the land to build anything higher than that. 900 is easier for players to see when their resolution is 640 x 480.

Max (walkable) land height is around 1024.

Objects

The object data starts at 0x14043 and carries on for the rest of the file. Each object is 55 bytes containing all the object's information. Most of the block is not used. The next object starts after the first object and so on. The total number of objects should be less than 2000.

For more information visit Object Data