source: Readingame/tools/cond.rehex.bt@ c52dd7b

main
Last change on this file since c52dd7b was c52dd7b, checked in by PulkoMandy <pulkomandy@…>, 8 weeks ago

Add rehex scripts in easy to use form

This is more convenient than having them on the wiki

  • Property mode set to 100644
File size: 387 bytes
Line 
1struct unknownchunk {
2 uint16_t size;
3 local uint16_t realLen = size - 2;
4 if (size > 0) {
5 char data[realLen];
6 }
7};
8
9struct recursechunk {
10 local uint16_t start = FTell();
11 uint16_t sizeInBytes;
12
13 struct unknownchunk innerchunks[0];
14 while (FTell() - start < sizeInBytes)
15 {
16 ArrayExtend(innerchunks);
17 }
18};
19
20struct recursechunk chunks[0];
21
22while (!FEof()) {
23 ArrayExtend(chunks);
24}
Note: See TracBrowser for help on using the repository browser.