diff --git a/basic/appleiibot/Makefile b/basic/appleiibot/Makefile index 8badb5a9..8faed03a 100644 --- a/basic/appleiibot/Makefile +++ b/basic/appleiibot/Makefile @@ -26,8 +26,8 @@ appleiibot.dsk: E2.BAS FLAME.BAS FLAME2.BAS HELLO \ PARTICLE_HGR.BAS DIAMOND_SCROLL.BAS RANDOM_SCROLL.BAS STAR_BOUNCE.BAS\ OOZE.BAS HORIZ_STAR.BAS SECRET_COLLECT.BAS PLANET.BAS PLANET_GR.BAS \ BOXES.BAS SOLARIS.BAS SOLARIS2.BAS ASPLODE.BAS SOLARIS3.BAS \ - TARGET.BAS - cp $(EMPTY_DISK)/empty.dsk appleiibot.dsk + TARGET.BAS ELITE.BAS + cp $(EMPTY_DISK)/empty_lots_of_dirents.dsk appleiibot.dsk # cp empty.dsk appleiibot.dsk # $(DOS33) -y appleiibot.dsk BSAVE -a 0x0300 LOAD $(DOS33) -y appleiibot.dsk SAVE A HELLO @@ -132,16 +132,12 @@ appleiibot.dsk: E2.BAS FLAME.BAS FLAME2.BAS HELLO \ $(DOS33) -y appleiibot.dsk SAVE A PLANET.BAS $(DOS33) -y appleiibot.dsk SAVE A PLANET_GR.BAS $(DOS33) -y appleiibot.dsk SAVE A BOXES.BAS -# $(DOS33) -y appleiibot.dsk SAVE A SOLARIS.BAS -# $(DOS33) -y appleiibot.dsk SAVE A SOLARIS2.BAS + $(DOS33) -y appleiibot.dsk SAVE A SOLARIS.BAS + $(DOS33) -y appleiibot.dsk SAVE A SOLARIS2.BAS $(DOS33) -y appleiibot.dsk SAVE A ASPLODE.BAS $(DOS33) -y appleiibot.dsk SAVE A SOLARIS3.BAS $(DOS33) -y appleiibot.dsk SAVE A TARGET.BAS - -#appleiibot2.dsk: BOXES.BAS HELLO -# cp empty.dsk appleiibot2.dsk -# $(DOS33) -y appleiibot2.dsk SAVE A HELLO -# $(DOS33) -y appleiibot2.dsk SAVE A BOXES.BAS + $(DOS33) -y appleiibot.dsk SAVE A ELITE.BAS #### @@ -773,6 +769,11 @@ ASPLODE.BAS: asplode.bas TARGET.BAS: target.bas $(TOKENIZE) < target.bas > TARGET.BAS +#### + +ELITE.BAS: elite.bas + $(TOKENIZE) < elite.bas > ELITE.BAS + #### diff --git a/basic/appleiibot/elite.bas b/basic/appleiibot/elite.bas new file mode 100644 index 00000000..d625f847 --- /dev/null +++ b/basic/appleiibot/elite.bas @@ -0,0 +1,7 @@ +0REM~*:B6S6l;`ALB5@):~B9B>I?I8B9~L8L?T>T:L8"~4-;8NEaNnPZ?L74-N5YI?I8B9~L8L?T>T:L8"~4-;8NEaNnPZ?L74-N5Y #include +static int debug=1; + +/* if div=3 */ +/* can't plot at 0 or 279 */ +/* min is 3 = 1 to 276 = 92 */ +/* add = 33 so from 34 to 125 */ + +/* if div=2 */ +/* can't plot at 0 or 184 */ +/* min is 2 = 1 to 184 = 92 */ +/* centered on screen that's roughly 50 - 234 */ + int main(int argc, char **argv) { char buffer[1024]; @@ -9,9 +21,20 @@ int main(int argc, char **argv) { char output[1024]; int out_ptr=0; int add=33; + int xadjust=0; + int div=3; if (argc>1) { - add=atoi(argv[1]); + div=atoi(argv[1]); + } + + if (div==2) { + xadjust=-50; + } + + if (debug) { + fprintf(stderr,"Using div=%d add=%d xadjust=%d\n", + div,add,xadjust); } while(1) { @@ -21,23 +44,27 @@ int main(int argc, char **argv) { if (buffer[0]=='#') continue; sscanf(buffer,"%d %d %d %d %d", &a1,&a2,&a3,&a4,&a5); - printf("%d %d %d %d %d\n",a1,a2,a3,a4,a5); + if (debug) fprintf(stderr,"%d %d %d %d %d\n",a1,a2,a3,a4,a5); if (a1==279) { - output[out_ptr]=(a1/3)+add; - output[out_ptr+1]=(a2/3)+add; - output[out_ptr+2]=(a3/3)+add; - output[out_ptr+3]=(a4/3)+add; - output[out_ptr+4]=(a5/3)+add; + output[out_ptr]=((a1-xadjust)/div)+add; + output[out_ptr+1]=((a2-xadjust)/div)+add; + output[out_ptr+2]=((a3-xadjust)/div)+add; + output[out_ptr+3]=((a4-xadjust)/div)+add; + output[out_ptr+4]=((a5-xadjust)/div)+add; out_ptr+=5; } + else if (a1==3) { + output[out_ptr]=((a1-xadjust)/div)+add; + out_ptr+=1; + } else if (a1==0) { - output[out_ptr]=(a1/3)+add; + output[out_ptr]=((a1-xadjust)/div)+add; out_ptr+=1; break; } else { - output[out_ptr]=(a1/3)+add; - output[out_ptr+1]=(a2/3)+add; + output[out_ptr]=((a1-xadjust)/div)+add; + output[out_ptr+1]=((a2-xadjust)/div)+add; out_ptr+=2; } } diff --git a/empty_disk/empty_lots_of_dirents.dsk b/empty_disk/empty_lots_of_dirents.dsk new file mode 100644 index 00000000..01fd92b6 Binary files /dev/null and b/empty_disk/empty_lots_of_dirents.dsk differ diff --git a/games/lemm/TODO b/games/lemm/TODO index fcc3bb17..884a59da 100644 --- a/games/lemm/TODO +++ b/games/lemm/TODO @@ -1,3 +1,6 @@ + +be sure that clicking on digger twice doesn't decrement twice + Improve explosions + offset the frames when nuking so not simultaneous + on explosion, start with invisible 6 so we always get a full 5s diff --git a/graphics/hgr/solaris/Makefile b/graphics/hgr/solaris/Makefile index 2f33d85a..5117b33f 100644 --- a/graphics/hgr/solaris/Makefile +++ b/graphics/hgr/solaris/Makefile @@ -7,13 +7,14 @@ EMPTYDISK = ../../../empty_disk/empty.dsk all: solaris.dsk -solaris.dsk: HELLO SOLARIS SOLARIS2 SOLARIS3 SOLARIS4 +solaris.dsk: HELLO SOLARIS SOLARIS2 SOLARIS3 SOLARIS4 SOLARIS_BOT cp $(EMPTYDISK) solaris.dsk $(DOS33) -y solaris.dsk SAVE A HELLO $(DOS33) -y solaris.dsk BSAVE -a 0xc00 SOLARIS $(DOS33) -y solaris.dsk BSAVE -a 0xc00 SOLARIS2 $(DOS33) -y solaris.dsk BSAVE -a 0xc00 SOLARIS3 $(DOS33) -y solaris.dsk BSAVE -a 0xc00 SOLARIS4 + $(DOS33) -y solaris.dsk BSAVE -a 0x3F5 SOLARIS_BOT ### @@ -54,9 +55,18 @@ SOLARIS4: solaris4.o solaris4.o: solaris4.s ca65 -o solaris4.o solaris4.s -l solaris4.lst +### + +SOLARIS_BOT: solaris_bot.o + ld65 -o SOLARIS_BOT solaris_bot.o -C $(LINKERSCRIPTS)/apple2_3f5.inc + +solaris_bot.o: solaris_bot.s + ca65 -o solaris_bot.o solaris_bot.s -l solaris_bot.lst + ### clean: - rm -f *~ *.o *.lst HELLO SOLARIS SOLARIS2 SOLARIS3 SOLARIS4 + rm -f *~ *.o *.lst HELLO SOLARIS SOLARIS2 SOLARIS3 SOLARIS4 SOLARIS_BOT + diff --git a/music/cd/Makefile b/music/cd/Makefile index 9234dbce..8d4d35f4 100644 --- a/music/cd/Makefile +++ b/music/cd/Makefile @@ -7,10 +7,11 @@ EMPTYDISK = ../../empty_disk/empty.dsk all: cd.dsk -cd.dsk: HELLO HORIZ +cd.dsk: HELLO HORIZ HORIZ_BOT cp $(EMPTYDISK) cd.dsk $(DOS33) -y cd.dsk SAVE A HELLO $(DOS33) -y cd.dsk BSAVE -a 0xC00 HORIZ + $(DOS33) -y cd.dsk BSAVE -a 0x370 HORIZ_BOT ### @@ -25,7 +26,16 @@ HORIZ: horiz.o horiz.o: horiz.s ca65 -o horiz.o horiz.s -l horiz.lst +### + +HORIZ_BOT: horiz_bot.o + ld65 -o HORIZ_BOT horiz_bot.o -C $(LINKERSCRIPTS)/apple2_370.inc + +horiz_bot.o: horiz_bot.s + ca65 -o horiz_bot.o horiz_bot.s -l horiz_bot.lst + + #### clean: - rm -f *~ *.o *.lst HORIZ + rm -f *~ *.o *.lst HORIZ HORIZ_BOT diff --git a/music/cd/horiz_bot.s b/music/cd/horiz_bot.s index 982ed55b..3bfd4c33 100644 --- a/music/cd/horiz_bot.s +++ b/music/cd/horiz_bot.s @@ -6,6 +6,8 @@ ; 156 bytes = BIT trick ; 154 bytes = set offsets properly ; 151 bytes = redo init +; 145 bytes = leave OFFSET_POINTER in X +; 136 bytes = get rid of end offsets GBASL = $26 GBASH = $27 @@ -45,8 +47,8 @@ horiz: forever_loop: - lda #$0 ; offset into the length pointers - sta OFFSET_POINTER + lda #$0 + tax ; X = OFFSET_POINTER into length pointers ; A = screen line, 0..24 big_loop: @@ -55,7 +57,6 @@ big_loop: jsr BASCALC ; calculate address of line in BASL/BASH ldy #39 ; draw 40 pixels on screen - ldx OFFSET_POINTER ; get pointer to the offsets hlin: tya @@ -71,7 +72,8 @@ gurg: tya clc - sbc endoffsets,X + sbc offsets,X + sbc #30 bvs gurg2 eor #$80 gurg2: @@ -103,10 +105,12 @@ blah: adc offsets,X sta BASL - ldx LINE ; which line of bitmap to use + ldy LINE ; which line of bitmap to use + + lda star_bitmap-1,Y ; get low bit of bitmap into carry ldy #7 ; 8-bits wide - lda star_bitmap-1,X ; get low bit of bitmap into carry + draw_line_loop: lsr @@ -125,10 +129,6 @@ its_transparent: skip_star: - - - ldx OFFSET_POINTER - ; see if new offset (meaning, we've gone three lines) dec LINE @@ -142,10 +142,15 @@ skip_star: lda #$b3 sta color_smc+1 ; add shadow to (top?) of line - dec offsets,X ; scroll the line length - dec endoffsets,X - inc OFFSET_POINTER ; point to next set of offsets + dec offsets,X ; scroll the line length + +; lda offsets,X +; and #$7f +; sta offsets,X + + + inx ; point to next set of offsets lda #3 ; reset line vlue sta LINE @@ -156,12 +161,9 @@ not3: pla ; restore line count clc - adc #1 - cmp #24 -; tax + adc #1 ; increment -; inx -; cpx #24 ; see if reached bottom + cmp #24 ; see if reached bottom bne big_loop @@ -179,8 +181,8 @@ not3: offsets: .byte 30,29,31,38,31,34,32,35 -endoffsets: - .byte 60,50,61,68,61,64,62,65 +;endoffsets: +; .byte 60,50,61,68,61,64,62,65 ; 76543210