appleiibot: oops
This commit is contained in:
parent
c14d20ca27
commit
d24ed0f461
|
@ -21,7 +21,7 @@ appleiibot.dsk: E2.BAS FLAME.BAS FLAME2.BAS HELLO \
|
||||||
FIREWORKS.BAS THINKING.BAS ARCS.BAS WIRE_HGR.BAS STATIC.BAS \
|
FIREWORKS.BAS THINKING.BAS ARCS.BAS WIRE_HGR.BAS STATIC.BAS \
|
||||||
OVAL.BAS OVAL_HGR.BAS MOVING.BAS THICK_SINE.BAS TURKEY.BAS \
|
OVAL.BAS OVAL_HGR.BAS MOVING.BAS THICK_SINE.BAS TURKEY.BAS \
|
||||||
FLAME_HGR.BAS RECT.BAS SNOWY.BAS EDGAR.BAS OOPS4.BAS OOPS3.BAS \
|
FLAME_HGR.BAS RECT.BAS SNOWY.BAS EDGAR.BAS OOPS4.BAS OOPS3.BAS \
|
||||||
HORROR.BAS DIAMOND.BAS LEMM.BAS
|
HORROR.BAS DIAMOND.BAS LEMM.BAS OOPS.BAS
|
||||||
# cp $(EMPTY_DISK)/empty.dsk appleiibot.dsk
|
# cp $(EMPTY_DISK)/empty.dsk appleiibot.dsk
|
||||||
cp empty.dsk appleiibot.dsk
|
cp empty.dsk appleiibot.dsk
|
||||||
$(DOS33) -y appleiibot.dsk BSAVE -a 0x0300 LOAD
|
$(DOS33) -y appleiibot.dsk BSAVE -a 0x0300 LOAD
|
||||||
|
@ -114,6 +114,7 @@ appleiibot.dsk: E2.BAS FLAME.BAS FLAME2.BAS HELLO \
|
||||||
$(DOS33) -y appleiibot.dsk SAVE A HORROR.BAS
|
$(DOS33) -y appleiibot.dsk SAVE A HORROR.BAS
|
||||||
$(DOS33) -y appleiibot.dsk SAVE A DIAMOND.BAS
|
$(DOS33) -y appleiibot.dsk SAVE A DIAMOND.BAS
|
||||||
$(DOS33) -y appleiibot.dsk SAVE A LEMM.BAS
|
$(DOS33) -y appleiibot.dsk SAVE A LEMM.BAS
|
||||||
|
$(DOS33) -y appleiibot.dsk SAVE A OOPS.BAS
|
||||||
|
|
||||||
####
|
####
|
||||||
|
|
||||||
|
@ -620,6 +621,11 @@ OOPS4.BAS: oops4.bas
|
||||||
OOPS3.BAS: oops3.bas
|
OOPS3.BAS: oops3.bas
|
||||||
$(TOKENIZE) < oops3.bas > OOPS3.BAS
|
$(TOKENIZE) < oops3.bas > OOPS3.BAS
|
||||||
|
|
||||||
|
####
|
||||||
|
|
||||||
|
OOPS.BAS: oops.bas
|
||||||
|
$(TOKENIZE) < oops.bas > OOPS.BAS
|
||||||
|
|
||||||
|
|
||||||
####
|
####
|
||||||
|
|
||||||
|
|
|
@ -14,14 +14,22 @@
|
||||||
|
|
||||||
int main(int argc, char **argv) {
|
int main(int argc, char **argv) {
|
||||||
|
|
||||||
int mode=END_AT_3F5;
|
int mode=BEGIN_AT_3F5;
|
||||||
// int mode=BEGIN_AT_3F5;
|
|
||||||
int i = 0;
|
int i = 0;
|
||||||
int e = 0,filesize;
|
int e = 0,filesize;
|
||||||
int val,pv,final;
|
int val,pv,final;
|
||||||
unsigned char in[1024];
|
unsigned char in[1024];
|
||||||
unsigned char enc[1024],enc2[1024];
|
unsigned char enc[1024],enc2[1024];
|
||||||
int third,enc_ptr=0;
|
int third,enc_ptr=0;
|
||||||
|
int filesize_digits;
|
||||||
|
|
||||||
|
if (argc>1) {
|
||||||
|
if (argv[1][0]=='-') {
|
||||||
|
if (argv[1][1]=='e') {
|
||||||
|
mode=END_AT_3F5;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// printf("1REM");
|
// printf("1REM");
|
||||||
|
|
||||||
|
@ -113,15 +121,20 @@ int main(int argc, char **argv) {
|
||||||
printf("2CALL768\"%s%s\n",enc2,enc);
|
printf("2CALL768\"%s%s\n",enc2,enc);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
if ((filesize-1)<10) filesize_digits=1;
|
||||||
|
else if ((filesize-1)<100) filesize_digits=2;
|
||||||
|
else filesize_digits=3;
|
||||||
|
|
||||||
if (mode==END_AT_3F5) {
|
if (mode==END_AT_3F5) {
|
||||||
fprintf(stderr,"Ending at $3F5\n");
|
fprintf(stderr,"Ending at $3F5\n");
|
||||||
printf("1FORI=0TO%d:POKE%d+I,4*PEEK(%d+I)-"
|
printf("1FORI=0TO%d:POKE%d+I,4*PEEK(%d+I)-"
|
||||||
"%d+(PEEK(%d+I/3)-%d)/4^(I-INT(I/3)*3):NEXT\n",
|
"%d+(PEEK(%d+I/3)-%d)/4^(I-INT(I/3)*3):NEXT\n",
|
||||||
filesize-1,
|
filesize-1, // filesize for loop
|
||||||
0x3f5-filesize+3,
|
0x3f5-filesize+3, // destination
|
||||||
2125,
|
2122+filesize_digits, // read from 6
|
||||||
64+4*OFFSET,
|
64+4*OFFSET, // ??
|
||||||
2125+filesize,OFFSET2);
|
2122+filesize+filesize_digits, // read from 2
|
||||||
|
OFFSET2);
|
||||||
printf("2&\"%s%s\n",enc2,enc);
|
printf("2&\"%s%s\n",enc2,enc);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -129,14 +142,14 @@ int main(int argc, char **argv) {
|
||||||
// if using & to jump to beginning (over-writing text page)
|
// if using & to jump to beginning (over-writing text page)
|
||||||
if (mode==BEGIN_AT_3F5) {
|
if (mode==BEGIN_AT_3F5) {
|
||||||
fprintf(stderr,"Beginning at $3F5\n");
|
fprintf(stderr,"Beginning at $3F5\n");
|
||||||
|
|
||||||
printf("1FORI=0TO%d:POKE%d+I,4*PEEK(%d+I)-"
|
printf("1FORI=0TO%d:POKE%d+I,4*PEEK(%d+I)-"
|
||||||
"%d+(PEEK(%d+I/3)-%d)/4^(I-INT(I/3)*3):NEXT\n",
|
"%d+(PEEK(%d+I/3)-%d)/4^(I-INT(I/3)*3):NEXT\n",
|
||||||
filesize-1,
|
filesize-1, // filesize for loop
|
||||||
0x3f5,
|
0x3f5, // destination
|
||||||
2126,
|
2123+filesize_digits, // read from 6
|
||||||
4*OFFSET+64,
|
4*OFFSET+64, // ?
|
||||||
2126+filesize,OFFSET2);
|
2123+filesize+filesize_digits, // read from 2
|
||||||
|
OFFSET2);
|
||||||
printf("2&\"%s%s\n",enc2,enc);
|
printf("2&\"%s%s\n",enc2,enc);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,2 @@
|
||||||
|
1FORI=0TO82:POKE1013+I,4*PEEK(2125+I)-204+(PEEK(2208+I/3)-35)/4^(I-INT(I/3)*3):NEXT
|
||||||
|
2&"/foT5aXnE?DYO2XBBr@M3Y[3TV]+ceom7iTl[3Tp[3Nq\e:B\`O4MKYr['8Hfjrirgcl:,:rA3\_BrTlF94SAJ=3W'$4C#.#.=Y))1SK1LC;W$$
|
Binary file not shown.
Before Width: | Height: | Size: 2.6 KiB After Width: | Height: | Size: 19 KiB |
|
@ -4,7 +4,10 @@ all: inventory_sprites.inc ending_sprites.inc trogdor_sprites.inc \
|
||||||
boat_sprites.inc boat_sprites_fish.inc peasant_sprites.inc ned_sprites.inc \
|
boat_sprites.inc boat_sprites_fish.inc peasant_sprites.inc ned_sprites.inc \
|
||||||
peasant_robe_sprites.inc kerrek_sprites.inc \
|
peasant_robe_sprites.inc kerrek_sprites.inc \
|
||||||
waterfall_sprites.inc bubble_sprites_w.inc bubble_sprites_e.inc \
|
waterfall_sprites.inc bubble_sprites_w.inc bubble_sprites_e.inc \
|
||||||
river_bubble_sprites.inc gary_sprites.inc
|
river_bubble_sprites.inc gary_sprites.inc archery_sprites.inc
|
||||||
|
|
||||||
|
archery_sprites.inc: archery_sprites.png
|
||||||
|
$(HGR_SPRITE) -s -l mendelev1_sprite archery_sprites.png 7 29 20 33 > archery_sprites.inc
|
||||||
|
|
||||||
peasant_sprites.inc: peasant_sprites.png
|
peasant_sprites.inc: peasant_sprites.png
|
||||||
$(HGR_SPRITE) -l peasant_right1_sprite peasant_sprites.png 35 1 35 29 > peasant_sprites.inc
|
$(HGR_SPRITE) -l peasant_right1_sprite peasant_sprites.png 35 1 35 29 > peasant_sprites.inc
|
||||||
|
|
Binary file not shown.
After Width: | Height: | Size: 7.4 KiB |
|
@ -16,7 +16,7 @@ sines.dsk: HELLO APPROX_SINE THICK_SINE THICK_COS TABLE_SINE ROM_SINE \
|
||||||
$(DOS33) -y sines.dsk BSAVE -a 0xc00 ROM_SINE
|
$(DOS33) -y sines.dsk BSAVE -a 0xc00 ROM_SINE
|
||||||
$(DOS33) -y sines.dsk BSAVE -a 0xc00 THICK_SINE
|
$(DOS33) -y sines.dsk BSAVE -a 0xc00 THICK_SINE
|
||||||
$(DOS33) -y sines.dsk BSAVE -a 0xc00 THICK_COS
|
$(DOS33) -y sines.dsk BSAVE -a 0xc00 THICK_COS
|
||||||
$(DOS33) -y sines.dsk BSAVE -a 0xc00 OOPS_COS
|
$(DOS33) -y sines.dsk BSAVE -a 0x3f5 OOPS_COS
|
||||||
$(DOS33) -y sines.dsk BSAVE -a 0xc00 OOPS2_COS
|
$(DOS33) -y sines.dsk BSAVE -a 0xc00 OOPS2_COS
|
||||||
$(DOS33) -y sines.dsk BSAVE -a 0x3f5 OOPS3_COS
|
$(DOS33) -y sines.dsk BSAVE -a 0x3f5 OOPS3_COS
|
||||||
$(DOS33) -y sines.dsk BSAVE -a 0x3f5 OOPS4_COS
|
$(DOS33) -y sines.dsk BSAVE -a 0x3f5 OOPS4_COS
|
||||||
|
@ -64,7 +64,7 @@ thick.o: thick.s
|
||||||
###
|
###
|
||||||
|
|
||||||
OOPS_COS: oops_cos.o
|
OOPS_COS: oops_cos.o
|
||||||
ld65 -o OOPS_COS oops_cos.o -C $(LINKERSCRIPTS)/apple2_c00.inc
|
ld65 -o OOPS_COS oops_cos.o -C $(LINKERSCRIPTS)/apple2_3f5.inc
|
||||||
|
|
||||||
oops_cos.o: oops_cos.s
|
oops_cos.o: oops_cos.s
|
||||||
ca65 -o oops_cos.o oops_cos.s -l oops_cos.lst
|
ca65 -o oops_cos.o oops_cos.s -l oops_cos.lst
|
||||||
|
|
|
@ -61,7 +61,7 @@ rectangle:
|
||||||
jsr HGR2 ; set hi-res 140x192, page2, fullscreen
|
jsr HGR2 ; set hi-res 140x192, page2, fullscreen
|
||||||
; A and Y both 0 at end
|
; A and Y both 0 at end
|
||||||
|
|
||||||
over:
|
again:
|
||||||
; clear our zp things to 0
|
; clear our zp things to 0
|
||||||
|
|
||||||
ldx #15
|
ldx #15
|
||||||
|
@ -112,7 +112,7 @@ main_loop:
|
||||||
end:
|
end:
|
||||||
txa ; put zero into A
|
txa ; put zero into A
|
||||||
inc color_smc+1
|
inc color_smc+1
|
||||||
bne over
|
bne again
|
||||||
|
|
||||||
|
|
||||||
;=================================
|
;=================================
|
||||||
|
@ -145,6 +145,7 @@ out_loop:
|
||||||
lda GBASH_SAVED
|
lda GBASH_SAVED
|
||||||
sta GBASH
|
sta GBASH
|
||||||
ldy XX
|
ldy XX
|
||||||
|
|
||||||
in_loop:
|
in_loop:
|
||||||
|
|
||||||
color_smc:
|
color_smc:
|
||||||
|
@ -160,8 +161,9 @@ output_smc:
|
||||||
dex
|
dex
|
||||||
bne in_loop
|
bne in_loop
|
||||||
|
|
||||||
lda #25 ; wait a bit
|
; A here is $40 - $60 (64 - 96)
|
||||||
jsr WAIT
|
; lda #25 ; wait a bit
|
||||||
|
; jsr WAIT
|
||||||
|
|
||||||
check_x:
|
check_x:
|
||||||
clc
|
clc
|
||||||
|
|
Loading…
Reference in New Issue