Star Stable Online TGA PTE: Difference between revisions

From XentaxWiki
Jump to navigation Jump to search
imported>Ikskoks
imported>Ikskoks
 
(29 intermediate revisions by the same user not shown)
Line 1: Line 1:
== TGA ==  
== TGA, PTE ==  
* ''' Game ''':    Star Stable Online <br>  
* ''' Game ''':    Star Stable Online <br>  
* ''' Format Type ''':    Image <br>  
* ''' Format Type ''':    Image <br>  
Line 10: Line 10:
<pre>
<pre>
// Star Stable Online
// Star Stable Online
// TGA file format
// TGA/PTE file format




// file header - 25 bytes
// file header
8 bytes - unknown
x bytes - unknown
4 bytes (char) - compression type  // e.g. "DXT1"
4 bytes (char) - compression type  // e.g. "DXT1"
13 bytes - unknown
13 bytes - unknown
Line 20: Line 20:


// crn texture header (big endian) - 74 bytes
// crn texture header (big endian) - 74 bytes
2 bytes (char) - magic // "Hx"
74 bytes - CRN file header
2 bytes (uint16) - header size  // e.g. 106
2 bytes (uint16) - header CRC16
4 bytes (uint32) - data size 
2 bytes (uint16) - data CRC16
2 bytes (uint16) - width
2 bytes (uint16) - height
1 byte (uint8) - mipmap level index // 0 is the largest/first level
1 byte (uint8) - number of faces
1 byte (uint8) - format number
2 bytes (uint16) - flags
4 bytes (uint32) - reserved
4 bytes (uint32) - user data 0
4 bytes (uint32) - user data 1
 
8 bytes - color endpoints (palette structure)
8 bytes - color selectors (palette structure)
8 bytes - alpha endpoints (palette structure)
8 bytes - alpha selectors (palette structure)
 
2 bytes (uint16) - tables size
3 bytes - tables offsets
4 bytes - levels offsets
 
 
x bytes - encrypted image data


x bytes - compressed image data // uses custom compression
</pre>
</pre>
</div>
</div>


=== MultiEx BMS Script ===  
=== quickBMS Script ===  


Not written yet.
* [https://github.com/bartlomiejduda/Tools/blob/master/NEW%20Tools/Star%20Stable%20Online/Star_Stable_Online_PTE_TGA_script.bms Star_Stable_Online_PTE_TGA_script.bms]


=== Notes and Comments ===  
=== Notes and Comments ===  


* This is CRN texture file with added extra header. It is also encrypted with unknown algorithm.
* TGA/PTE files are CRN textures file with added extra header. They are also compressed with custom algorithm.
* CRC16 calculation can be described as below: <br>
<div class="toccolours mw-collapsible" id="mw-customcollapsible-myDivision" style="width:800px; overflow:auto;">
<pre>
// header crc16
const uint32 header_crc = crc16(&pHeader->m_data_size, (uint32)(pHeader->m_header_size - ((const uint8*)&pHeader->m_data_size - (const uint8*)pHeader)));


//data crc16
=== Compatible Programs ===
const uint32 data_crc = crc16((const uint8*)pData + pHeader->m_header_size, pHeader->m_data_size - pHeader->m_header_size);


// Note: More details in "crn_decomp.h" file.
* [https://github.com/BinomialLLC/crunch crunch]
</pre>
* [https://forum.xentax.com/download/file.php?id=21520 crunch_unity] (special crunch version compiled for Unity games)
</div>


=== Compatible Programs ===  
=== See Also ===


* [https://github.com/BinomialLLC/crunch crunch]
* [http://wiki.xentax.com/index.php/Crunch_CRN CRN file format (xentax wiki)]
<br/><br>
<br/><br>




[[Category:Complete WIP|Star Stable Online TGA]]
[[Category:Complete Almost Done|Star Stable Online TGA PTE]]
[[Category:Platform PC|Star Stable Online TGA]]
[[Category:Platform PC|Star Stable Online TGA PTE]]
[[Category:CE Compressed|Star Stable Online TGA]]
[[Category:CE Compressed|Star Stable Online TGA PTE]]
[[Category:Format_Image | Type: Image]]
[[Category:Format_Image | Type: Image]]
[[Category:Extension_tga | Extension: tga]]
[[Category:Extension_tga | Extension: tga]]
[[Category:BMS_None | BMS: None]]
[[Category:Extension_pte | Extension: pte]]
[[Category:DXT1 compression]]
[[Category:DXT1 compression]]
[[Category:DXT3 compression]]
[[Category:DXT3 compression]]
[[Category:DXT5 compression]]
[[Category:DXT5 compression]]
[[Category:Custom encryption]]
[[Category:File Format]]
[[Category:File Format]]

Latest revision as of 22:20, 29 January 2022

TGA, PTE

  • Game : Star Stable Online
  • Format Type : Image
  • Endian Order : Big Endian


Format Specifications

// Star Stable Online
// TGA/PTE file format


// file header
x bytes - unknown
4 bytes (char) - compression type  // e.g. "DXT1"
13 bytes - unknown


// crn texture header (big endian) - 74 bytes
74 bytes - CRN file header

x bytes - compressed image data // uses custom compression

quickBMS Script

Notes and Comments

  • TGA/PTE files are CRN textures file with added extra header. They are also compressed with custom algorithm.

Compatible Programs

See Also