| ... | ... |
@@ -6,7 +6,7 @@ |
| 6 | 6 |
( devices ) |
| 7 | 7 |
|
| 8 | 8 |
|00 @System [ &vector $2 &pad $6 &r $2 &g $2 &b $2 ] |
| 9 |
-|20 @Screen [ &vector $2 &width $2 &height $2 &pad $2 &x $2 &y $2 &addr $2 &pixel $1 &sprite $1 ] |
|
| 9 |
+|20 @Screen [ &vector $2 &width $2 &height $2 &auto $1 &pad $1 &x $2 &y $2 &addr $2 &pixel $1 &sprite $1 ] |
|
| 10 | 10 |
|a0 @File [ &vector $2 &success $2 &offset-hs $2 &offset-ls $2 &name $2 &length $2 &load $2 &save $2 ] |
| 11 | 11 |
|
| 12 | 12 |
( variables ) |
| ... | ... |
@@ -38,6 +38,19 @@ |
| 38 | 38 |
( load ) ;chr2-path #0900 LOAD-IMAGE |
| 39 | 39 |
( draw ) #0068 #0098 #0060 #0060 ;image #85 ;draw-chr JSR2 |
| 40 | 40 |
|
| 41 |
+ |
|
| 42 |
+ ( auto-x ) |
|
| 43 |
+ #01 .Screen/auto DEO |
|
| 44 |
+ #0070 .Screen/x DEO2 |
|
| 45 |
+ #0070 .Screen/y DEO2 |
|
| 46 |
+ ;checker-icn .Screen/addr DEO2 |
|
| 47 |
+ #03 .Screen/sprite DEO |
|
| 48 |
+ #03 .Screen/sprite DEO |
|
| 49 |
+ #03 .Screen/sprite DEO |
|
| 50 |
+ #03 .Screen/sprite DEO |
|
| 51 |
+ #03 .Screen/sprite DEO |
|
| 52 |
+ #00 .Screen/auto DEO |
|
| 53 |
+ |
|
| 41 | 54 |
BRK |
| 42 | 55 |
|
| 43 | 56 |
@draw-icn ( x* y* width* height* addr* color -- ) |
| ... | ... |
@@ -324,8 +324,8 @@ screen_talk(Device *d, Uint8 b0, Uint8 w) |
| 324 | 324 |
Uint16 y = peek16(d->dat, 0xa); |
| 325 | 325 |
Uint8 layer = d->dat[0xe] & 0x40; |
| 326 | 326 |
ppu_pixel(&ppu, !!layer, x, y, d->dat[0xe] & 0x3); |
| 327 |
- if(d->dat[0x6] & 0x1) poke16(d->dat, 0x8, x + 1); /* auto x+1 */ |
|
| 328 |
- if(d->dat[0x6] & 0x2) poke16(d->dat, 0xa, y + 1); /* auto y+1 */ |
|
| 327 |
+ if(d->dat[0x6] & 0x01) poke16(d->dat, 0x8, x + 1); /* auto x+1 */ |
|
| 328 |
+ if(d->dat[0x6] & 0x02) poke16(d->dat, 0xa, y + 1); /* auto y+1 */ |
|
| 329 | 329 |
reqdraw = 1; |
| 330 | 330 |
} else if(w && b0 == 0xf) {
|
| 331 | 331 |
Uint16 x = peek16(d->dat, 0x8); |
| ... | ... |
@@ -334,13 +334,13 @@ screen_talk(Device *d, Uint8 b0, Uint8 w) |
| 334 | 334 |
Uint8 *addr = &d->mem[peek16(d->dat, 0xc)]; |
| 335 | 335 |
if(d->dat[0xf] & 0x80) {
|
| 336 | 336 |
ppu_2bpp(&ppu, !!layer, x, y, addr, d->dat[0xf] & 0xf, d->dat[0xf] & 0x10, d->dat[0xf] & 0x20); |
| 337 |
- if(d->dat[0x6] & 0x3) poke16(d->dat, 0xc, peek16(d->dat, 0xc) + 16); /* auto addr+16 */ |
|
| 337 |
+ if(d->dat[0x6] & 0x04) poke16(d->dat, 0xc, peek16(d->dat, 0xc) + 16); /* auto addr+16 */ |
|
| 338 | 338 |
} else {
|
| 339 | 339 |
ppu_1bpp(&ppu, !!layer, x, y, addr, d->dat[0xf] & 0xf, d->dat[0xf] & 0x10, d->dat[0xf] & 0x20); |
| 340 |
- if(d->dat[0x6] & 0x3) poke16(d->dat, 0xc, peek16(d->dat, 0xc) + 8); /* auto addr+8 */ |
|
| 340 |
+ if(d->dat[0x6] & 0x04) poke16(d->dat, 0xc, peek16(d->dat, 0xc) + 8); /* auto addr+8 */ |
|
| 341 | 341 |
} |
| 342 |
- if(d->dat[0x6] & 0x1) poke16(d->dat, 0x8, x + 8); /* auto x+8 */ |
|
| 343 |
- if(d->dat[0x6] & 0x2) poke16(d->dat, 0xa, y + 8); /* auto y+8 */ |
|
| 342 |
+ if(d->dat[0x6] & 0x01) poke16(d->dat, 0x8, x + 8); /* auto x+8 */ |
|
| 343 |
+ if(d->dat[0x6] & 0x02) poke16(d->dat, 0xa, y + 8); /* auto y+8 */ |
|
| 344 | 344 |
reqdraw = 1; |
| 345 | 345 |
} |
| 346 | 346 |
return 1; |