diff --git a/basic/appleiibot/Makefile b/basic/appleiibot/Makefile index fb44ce46..4f3788e3 100644 --- a/basic/appleiibot/Makefile +++ b/basic/appleiibot/Makefile @@ -17,7 +17,7 @@ appleiibot.dsk: E2.BAS FLAME.BAS FLAME2.BAS HELLO \ COMBO.BAS WIRES.BAS PATTERN.BAS BALL.BAS LINES.BAS MOD9.BAS \ XOR_ZOOM.BAS MOD9_HGR.BAS SIER_HGR.BAS MOVE.BAS SINE.BAS XDRAW128.BAS \ GATOR.BAS CURSOR.BAS STARGATE.BAS TUNNEL.BAS STARFIELD.BAS \ - STAROOPS.BAS + STAROOPS.BAS HGRSTARFIELD.BAS # cp $(EMPTY_DISK)/empty.dsk appleiibot.dsk cp empty.dsk appleiibot.dsk @@ -88,6 +88,7 @@ appleiibot.dsk: E2.BAS FLAME.BAS FLAME2.BAS HELLO \ $(DOS33) -y appleiibot.dsk SAVE A TUNNEL.BAS $(DOS33) -y appleiibot.dsk SAVE A STARFIELD.BAS $(DOS33) -y appleiibot.dsk SAVE A STAROOPS.BAS + $(DOS33) -y appleiibot.dsk SAVE A HGRSTARFIELD.BAS #### @@ -489,6 +490,10 @@ BALL.BAS: ball.bas LINES.BAS: lines.bas $(TOKENIZE) < lines.bas > LINES.BAS +#### + +HGRSTARFIELD.BAS: hgrstarfield.bas + $(TOKENIZE) < hgrstarfield.bas > HGRSTARFIELD.BAS #### diff --git a/basic/appleiibot/hgrstarfield.bas b/basic/appleiibot/hgrstarfield.bas new file mode 100644 index 00000000..6da480bb --- /dev/null +++ b/basic/appleiibot/hgrstarfield.bas @@ -0,0 +1,2 @@ +1FORI=0TO139:POKE876+I,4*PEEK(2125+I)-192+(PEEK(2265+I/3)-35)/4^(I-INT(I/3)*3):NEXT +2&",clU68V.b*lX6XD,fnV/QgQn]LBUBZJX05EmUm]X7g/JHKnUK]T+d0JSZMBe(j4YgQfTZWoX$5EkYn7]0+^0V1^:\Yn^0kUTZ/lQ[^,k:210M.ioH2/0Bk5J$Uo^=m(2nV:4#?o6HCH0S1PK&S4+$D#/53*<'W$CCEC,S+SWU+*'445:D&76T3C#Y#/ diff --git a/basic/appleiibot/staroops.bas b/basic/appleiibot/staroops.bas index 1fb38613..131b2ff1 100644 --- a/basic/appleiibot/staroops.bas +++ b/basic/appleiibot/staroops.bas @@ -1,2 +1,2 @@ 1FORI=0TO131:POKE884+I,4*PEEK(2125+I)-192+(PEEK(2257+I/3)-35)/4^(I-INT(I/3)*3):NEXT -2&",clU68V.b*lX.V7,fnV/Qh]\+d0FGb`\:b0T0OoQK]P7g/JPZUDe0l2aiQnVQWoX08=kYnC`,7a.b4X:^Rn^,kUS^0kU\\0l3N2/U0foH.31?o6I0Xob>m04nV:./Bo6H7J0S1PKFS4'W4#$G43*#%-%I#F#6.F?3'(,@(130(&$%;&S +2&",clU68V.b*lX.V7,fnV/Qh]\+d0FGb`\:b0T0OoQK]P7g/JSZUDe0l2aiQnVQWoX08=kYnC`,7a.b4X:^Rn^,kUS^0kU\\0l3N2/U0foH.31?o6I0Xob>m04nV:./Bo6H7J0S1PKFS4'W4#$G43*#%-%I#F#6.F?3'(,@(130(&$%;&S diff --git a/graphics/hgr/starfield/Makefile b/graphics/hgr/starfield/Makefile index b2c9f430..73f6fa1a 100644 --- a/graphics/hgr/starfield/Makefile +++ b/graphics/hgr/starfield/Makefile @@ -12,7 +12,7 @@ starfield.dsk: HELLO STARS FASTAR STARBOT STARTINY STAROOPS $(DOS33) -y starfield.dsk SAVE A HELLO $(DOS33) -y starfield.dsk BSAVE -a 0x0300 STARS $(DOS33) -y starfield.dsk BSAVE -a 0x0C00 FASTAR - $(DOS33) -y starfield.dsk BSAVE -a 0x0C00 STARBOT + $(DOS33) -y starfield.dsk BSAVE -a 0x036C STARBOT $(DOS33) -y starfield.dsk BSAVE -a 0x0C00 STARTINY $(DOS33) -y starfield.dsk BSAVE -a 0x0374 STAROOPS @@ -41,7 +41,7 @@ stars.o: stars.s ### STARBOT: starbot.o - ld65 -o STARBOT starbot.o -C $(LINKER_SCRIPTS)/apple2_c00.inc + ld65 -o STARBOT starbot.o -C $(LINKER_SCRIPTS)/apple2_36c.inc starbot.o: starbot.s ca65 -o starbot.o starbot.s -l starbot.lst diff --git a/graphics/hgr/starfield/starbot.s b/graphics/hgr/starfield/starbot.s index 7935553b..3d9a7c22 100644 --- a/graphics/hgr/starfield/starbot.s +++ b/graphics/hgr/starfield/starbot.s @@ -7,6 +7,8 @@ ; 155 bytes -- scale to more of full screen ; 153 bytes -- blue/orange instead of purple/green ; 149 bytes -- optimize 2nd plot arg shuffling +; 148 bytes -- optimize 1st plot arg shuffling +; 140 bytes -- turn off all range checking except Z NUMSTARS = 27 ; 27 good, 28+ not work ($1C) @@ -85,7 +87,7 @@ big_loop: ; lda #100 ; jsr WAIT - ldy #30 + ldy #80 jsr BELL2 ; BEEP delays too ; A now 0 @@ -104,12 +106,11 @@ star_loop: stx SAVEX - ldy oldx,X ; get X valu into Y -; tya -; tax - sty TEMP lda oldy,X - ldx TEMP + pha + lda oldx,X ; get X valu into Y + tax + pla ldy #0 @@ -139,10 +140,10 @@ star_loop: ; if off-screen then need new star - cmp #192 - bcs new_star ; bge >39 - cmp #0 - bcc new_star ; if <0 +; cmp #192 +; bcs new_star ; bge >39 +; cmp #0 +; bcc new_star ; if <0 sta YY ; YY @@ -158,7 +159,7 @@ star_loop: lda star_x,X ; get X of start jsr do_divide - adc #128 + adc #140 ; center tay ; put XX in Y sty oldx,X ; save for next time to erase @@ -239,7 +240,7 @@ color_lookup: sta star_y,X ; random YY lda $F002,Y - and #$7f ; random ZZ 0..127 (can't go negative or stars move backward) + and #$1f ; random ZZ 0..127 (can't go negative or stars move backward) ora #$1 ; avoid 0 sta star_z,X @@ -294,5 +295,5 @@ early_out: ; for BASIC bot load ; need this to be at $3F5 - ; it's at 8C, so 6D + ; it's at 89, so 6C jmp small_starfield diff --git a/graphics/hgr/starfield/staroops.s b/graphics/hgr/starfield/staroops.s index 5d3a6a4e..ea93fce2 100644 --- a/graphics/hgr/starfield/staroops.s +++ b/graphics/hgr/starfield/staroops.s @@ -158,7 +158,7 @@ star_loop: lda star_x,X ; get X of start jsr do_divide - adc #128 + adc #140 ; center tay ; put XX in Y sty oldx,X ; save for next time to erase