... | ... |
@@ -44,7 +44,7 @@ |
44 | 44 |
;pt1 { x 2 y 2 } |
45 | 45 |
;pt2 { x 2 y 2 } ( paint-rect ) |
46 | 46 |
;px { x 1 y 1 } |
47 |
-;document { state 1 edit 1 namelength 1 name 48 } |
|
47 |
+;document { state 1 edit 1 namelength 1 name 20 } |
|
48 | 48 |
;timer { byte 1 } |
49 | 49 |
|
50 | 50 |
( devices ) |
... | ... |
@@ -308,26 +308,23 @@ BRK |
308 | 308 |
@on-document-edit |
309 | 309 |
|
310 | 310 |
~Keys #00 EQU ,$no-keys JNZ2 |
311 |
- |
|
312 | 311 |
~Keys #0d NEQ ,$no-enter JNZ2 |
313 | 312 |
#00 =document.edit |
314 | 313 |
,redraw JSR2 |
315 | 314 |
BRK |
316 | 315 |
$no-enter |
317 |
- |
|
318 | 316 |
~Keys #08 NEQ ,$no-backspace JNZ2 |
317 |
+ ~document.namelength #00 EQU ,$end JNZ2 |
|
319 | 318 |
( incr ) ~document.namelength #01 SUB =document.namelength |
320 | 319 |
,$end JSR2 |
321 | 320 |
BRK |
322 | 321 |
$no-backspace |
323 |
- |
|
322 |
+ ~document.namelength #1f EQU ,$end JNZ2 |
|
324 | 323 |
( store key ) ~Keys ,document.name #00 ~document.namelength ADD2 POK2 |
325 | 324 |
( incr ) ~document.namelength #01 ADD =document.namelength |
326 |
- |
|
327 | 325 |
$end |
328 | 326 |
( store end ) #00 ,document.name #00 ~document.namelength ADD2 POK2 |
329 | 327 |
( release ) #00 =Keys.key |
330 |
- |
|
331 | 328 |
$no-keys |
332 | 329 |
|
333 | 330 |
( move ) #0008 =Sprite.x ~Screen.height #0010 SUB2 =Sprite.y |
... | ... |
@@ -239,7 +239,7 @@ makevariable(char *name, Uint16 *addr, FILE *f) |
239 | 239 |
if(word[0] == '{') continue; |
240 | 240 |
if(word[0] == '}') break; |
241 | 241 |
scpy(word, l->map[l->maps].name, 64); |
242 |
- fscanf(f, "%u", &l->map[l->maps].size); |
|
242 |
+ fscanf(f, "%02x", &l->map[l->maps].size); |
|
243 | 243 |
*addr += l->map[l->maps].size; |
244 | 244 |
l->len += l->map[l->maps++].size; |
245 | 245 |
} |