diff options
-rw-r--r-- | docs/cronos-research.md | 38 |
1 files changed, 36 insertions, 2 deletions
diff --git a/docs/cronos-research.md b/docs/cronos-research.md index 75b9c61..ec074d7 100644 --- a/docs/cronos-research.md +++ b/docs/cronos-research.md | |||
@@ -125,14 +125,48 @@ Its first byte defines, which table it belongs to. It is encoded in cp1251 (or p | |||
125 | ## structure definitions | 125 | ## structure definitions |
126 | 126 | ||
127 | records start numbering at '1'. | 127 | records start numbering at '1'. |
128 | Names are stored as: `byte strlen + char value[strlen]` | ||
128 | 129 | ||
129 | The first entry contains: | 130 | The first entry contains: |
130 | 131 | ||
131 | byte | 132 | byte |
132 | array { | 133 | array { |
133 | byte strlen | 134 | Name keyname |
134 | char name[strlen] | ||
135 | uint32_t index_or_size; // size when bit31 is set. | 135 | uint32_t index_or_size; // size when bit31 is set. |
136 | byte data[size] | 136 | byte data[size] |
137 | } | 137 | } |
138 | 138 | ||
139 | this results in a dictionary, with keys like: `Bank`, `BankId`, `BankTable`, `Base`nnn, etc. | ||
140 | |||
141 | the `Base000` entry contains the record number for the table definition of the first table. | ||
142 | |||
143 | ## table definitions | ||
144 | |||
145 | byte version | ||
146 | word16 unk1 | ||
147 | word16 unk2 | ||
148 | word16 unk3 | ||
149 | word32 unk4 | ||
150 | word32 unk5 | ||
151 | Name tablename | ||
152 | Name unk6 | ||
153 | word32 unk7 | ||
154 | word32 nrfields | ||
155 | |||
156 | array { | ||
157 | word16 entrysize -- total nr of bytes in this entry. | ||
158 | word16 fieldtype 0 = sysnum, 2 = text, 4 = number | ||
159 | word32 fieldindex ?? | ||
160 | Name fieldname | ||
161 | word32 | ||
162 | byte | ||
163 | word32 fieldindex ?? | ||
164 | word32 fieldsize | ||
165 | word32 ? | ||
166 | ... | ||
167 | } fields[nrfields] | ||
168 | |||
169 | ... | ||
170 | |||
171 | |||
172 | |||