File Formats
Technical documentation for file formats that SPORE uses.
The following (C/C++) types are used in this document:
- uint32_t 4 byte unsigned integer (unsigned int)
- uint16_t 2 byte unsigned integer (unsigned short)
- uint8_t 1 byte unsigned (unsigned char)
- int32_t 4 byte signed integer (int)
- int16_t 2 byte signed integer (short)
- int8_t 1 byte signed (char)
- float 4 byte IEEE floating point number
Values stored in big endian order will be marked with BE. If not marked BE values are stored in little endian order. Swapping bytes from one order to another can be done like this in C++:
//swap byte order, needs STL algorithm
// usage example: uint32_t foo = 1234;
// endian_swap<uint32_t>( foo );
template<typename T>
inline void endian_swap( T &value ) {
uint8_t *p = reinterpret_cast<uint8_t *>( &value );
std::reverse( p, p + sizeof( T ) );
}
- PROP-file reference
- GMDL
- PLT
- creature_traits
- building_traits
- vehicle_traits
- GMSH
- trait_pill
- CSS (listed for completeness. Only information relevant to SPORE here.)
- trigger
- formation
- TTF (listed for completeness. Only information relevant to SPORE here.)
- summary
- summary_pill
- locale
- pollen_metadata
- HM
- HTRA
- XHTML (listed for completeness. Only information relevant to SPORE here.)
- raster
- JPEG (listed for completeness. Only information relevant to SPORE here.)
- PNG (listed for completeness. Only information relevant to SPORE here.)
- BMP (listed for completeness. Only information relevant to SPORE here.)
- TGA (listed for completeness. Only information relevant to SPORE here.)
- GIF (listed for completeness. Only information relevant to SPORE here.)
- TLSA
- PCTP
- XML (listed for completeness. Only information relevant to SPORE here.)
- layout(SPUI)
Based on the file format list found on Rick's Spore Stuff