Binary Spiral Template: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
|||
Line 47: | Line 47: | ||
===00 - Parse Data As=== | ===00 - Parse Data As=== | ||
Syntax: <code>00 [File Type]</code> | |||
Parses the data as a certain type. Primarily used to iterate through sub-entries. | |||
{| class="wikitable" | |||
!colspan="3"|Magic Numbers | |||
|- | |||
!Hex Value | |||
!Name | |||
|- | |||
|00 || [[Pak]] | |||
|- | |||
|01 || [[Spc]] | |||
|- | |||
|style="text-align:center;" colspan="3" | ... | |||
|- | |||
|FF | |||
|(Raw) | |||
|- | |||
|} | |||
===01 - Add Magic Number=== | ===01 - Add Magic Number=== |
Revision as of 13:45, 7 November 2019
Binary Spiral Templates (BST) are template files that use a set of opcodes to modify files to fit a certain binary format. These are used by Spiral to coerce some format files into being more easily and sanely recogniseable (such as Pak archives).
Specification
BST Opcodes | |||
---|---|---|---|
Hex Opcode | Name | Argument Count | Comments |
00 | Parse Data As | 1 | |
01 | Add Magic Number | 1 | |
02 | Iterate Subfiles | 0 | |
03 | Done | 0 | |
04 | Break | 0 | Does not flush output |
05 | Skip | 0 |
Opcodes
00 - Parse Data As
Syntax: 00 [File Type]
Parses the data as a certain type. Primarily used to iterate through sub-entries.
Magic Numbers | ||
---|---|---|
Hex Value | Name | |
00 | Pak | |
01 | Spc | |
... | ||
FF | (Raw) |
01 - Add Magic Number
Syntax: 00 [Magic Number]
Magic Numbers | ||
---|---|---|
Hex Opcode | Hex Magic Number (LE) | Name |
00 | 2E 50 41 4B
|
Pak |
... | ||
FC | N/a | (Raw Int8) |
FD | N/a | (Raw Int16) |
FE | N/a | (Raw Int32) |
FF | N/a | (Raw Int64) |