build 130

This commit is contained in:
2022-03-13 14:49:15 -04:00
parent 55e52ac270
commit cc3bc492fc
8 changed files with 95 additions and 51 deletions
+5
View File
@@ -40,6 +40,11 @@ with the advent of fujinet (https://fujinet.online/) we are thinking about makin
## Changes: ## Changes:
###### Build 130
2022-03-13
- fixed bug: Decreasing of number of bullets after a shoot does not work correctly. It does look like it is fixed, although all I did was moving decreasing before shooting. Displaying number of bullets immediately after shoot.
- fixed a very difficult bug - game was crashing from time to time, with corrupted code and/or screen. It was digger digging lower and lower, finally digging through the code. Right now the game is not crashing on me.
###### Build 129 ###### Build 129
2022-03-06 2022-03-06
- added tune by emkay, lzss player by dmsc - added tune by emkay, lzss player by dmsc
+7 -4
View File
@@ -8,11 +8,9 @@ Known bugs (+ means bug is fixed)
(and uses one parachute more than necessary) (and uses one parachute more than necessary)
005. tank stands still on a one pixel spike - it should fall 005. tank stands still on a one pixel spike - it should fall
(possibly all that is necessary is adjust of WhereToSlideTable) (possibly all that is necessary is adjust of WhereToSlideTable)
007. Decreasing of number of bullets after a shoot does not work correctly
(e.g. 2 bullets are deducted instead of 1)
017: Observed MIRV loops - it shoots and shoots MIRV all over the screen. Very rare. 017: Observed MIRV loops - it shoots and shoots MIRV all over the screen. Very rare.
020: sometimes leftmost or rightmost remains of the funkybomb smoke do not get cleared 020: sometimes leftmost or rightmost remains of the funkybomb smoke do not get cleared
022: shooting funkybomb decreases number of bombs too much! (2 instead of 1?) I think it happens when one of the bombs goes out of the screen
Fixed: Fixed:
+001. when bullet goes straight down very fast it misses the tank +001. when bullet goes straight down very fast it misses the tank
@@ -42,7 +40,11 @@ Fixed:
+019: AI menu does not recognize keyboard up (prints "-" in tank name) +019: AI menu does not recognize keyboard up (prints "-" in tank name)
+021: check MWA, ADW, SBW macros - bad modifications of bytes found!!! +021: check MWA, ADW, SBW macros - bad modifications of bytes found!!!
+009. When result in points is >99 then only 2 first digits are displayed +009. When result in points is >99 then only 2 first digits are displayed
-022: shooting funkybomb decreases number of bombs too much! (2 instead of 1?)
+007. Decreasing of number of bullets after a shoot does not work correctly
(e.g. 2 bullets are deducted instead of 1) FUNKYBOMB!!!
it looks like it is fixed, although what I did was moving decreasing before jsr shoot
+000, Game crashes from time to time, code and/or screen gets corrupted
--------------------------------------------------------- ---------------------------------------------------------
@@ -64,6 +66,7 @@ To do
020. Not a bug per se, but ydraw variable is word, possibly it can be switched to byte 020. Not a bug per se, but ydraw variable is word, possibly it can be switched to byte
021. Add player colors to purchase screen 021. Add player colors to purchase screen
022. Make colors more contrasting 022. Make colors more contrasting
023. Make not implemented weapons raise NotImplementedError :]
Done: Done:
+1 -1
View File
@@ -77,7 +77,7 @@ PlotLine = display + screenHeight*screenBytes ; the last line is plot pointer
;Screen displays go first to avoid crossing 4kb barrier ;Screen displays go first to avoid crossing 4kb barrier
;----------------------------------------------- ;-----------------------------------------------
OptionsScreen OptionsScreen
dta d"Welcome to Scorch ver. 129 (un)2000-2022" dta d"Welcome to Scorch ver. 130 (un)2000-2022"
dta d" Please select option with cursor keys " dta d" Please select option with cursor keys "
dta d" and press (Return) to proceed " dta d" and press (Return) to proceed "
OptionsHere OptionsHere
+5 -5
View File
@@ -1289,17 +1289,17 @@ CopyMask
and #$7 and #$7
sta ybit sta ybit
lsrw xbyte lsrw xbyte ; div 8
rorw xbyte rorw xbyte
rorw xbyte rorw xbyte
;--- ;---
ldy xbyte ldy xbyte
ldx ydraw lda ydraw ; y = y - 7 because left lower. shouldn't it be 8?
.rept 7 sec
dex sbc #7
.endr tax
lda linetableL,x lda linetableL,x
sta xbyte sta xbyte
+4 -2
View File
@@ -405,6 +405,9 @@ ManualShooting
jsr BeforeFire jsr BeforeFire
AfterManualShooting AfterManualShooting
jsr DecreaseWeaponBeforeShoot
jsr DisplayingSymbols
; lower energy to eventually let tanks commit suicide ; lower energy to eventually let tanks commit suicide
ldx TankNr ldx TankNr
dec Energy,x dec Energy,x
@@ -454,7 +457,6 @@ missed
mva #0 plot4x4color mva #0 plot4x4color
jsr DisplayOffensiveTextNr jsr DisplayOffensiveTextNr
jsr DecreaseWeaponAfterShoot ; or before???
NextPlayerShoots NextPlayerShoots
mva #1 Erase mva #1 Erase
jsr drawtanks jsr drawtanks
@@ -523,7 +525,7 @@ PlayersAgain .proc
; additionally this tank just have had LASTeXistenZ set to 0, ; additionally this tank just have had LASTeXistenZ set to 0,
; otherwise it would explode again and again. ; otherwise it would explode again and again.
; OK, text how to do it is ready, now comes coding . ; OK, text how to do it is ready, now comes coding .
; Aaaah! - in main loop we have to set eXistenZ and LASTeXistenZ ; Aaaah! - in the main loop we have to set eXistenZ and LASTeXistenZ
ldx NumberOfPlayers ldx NumberOfPlayers
dex dex
BIN
View File
Binary file not shown.
-1
View File
@@ -149,7 +149,6 @@ skip10
sta gravity sta gravity
;fourth option (wind) ;fourth option (wind)
ldy OptionsTable+3 ldy OptionsTable+3
lda MaxWindTable,y lda MaxWindTable,y
sta MaxWind sta MaxWind
+73 -38
View File
@@ -3,31 +3,35 @@
.IF *>0 ;this is a trick that prevents compiling this file alone .IF *>0 ;this is a trick that prevents compiling this file alone
; ------------------------ ; ------------------------
babymissile .proc babymissile
inc FallDown2 inc FallDown2
mva #11 ExplosionRadius mva #11 ExplosionRadius
jsr CalculateExplosionRange jsr CalculateExplosionRange
jmp xmissile jmp xmissile
.endp
; ------------------------ ; ------------------------
missile ; .proc missile ;
inc FallDown2 inc FallDown2
mva #17 ExplosionRadius mva #17 ExplosionRadius
jsr CalculateExplosionRange jsr CalculateExplosionRange
jmp xmissile jmp xmissile
.endp
; ------------------------ ; ------------------------
babynuke .proc babynuke
inc FallDown2 inc FallDown2
mva #25 ExplosionRadius mva #25 ExplosionRadius
jsr CalculateExplosionRange jsr CalculateExplosionRange
jmp xmissile jmp xmissile
.endp
; ------------------------ ; ------------------------
nuke .proc nuke
inc FallDown2 inc FallDown2
mva #31 ExplosionRadius mva #31 ExplosionRadius
jsr CalculateExplosionRange jsr CalculateExplosionRange
jmp xmissile jmp xmissile
.endp
; ------------------------ ; ------------------------
leapfrog .proc leapfrog
inc FallDown2 inc FallDown2
mva #17 ExplosionRadius mva #17 ExplosionRadius
jsr CalculateExplosionRange jsr CalculateExplosionRange
@@ -98,12 +102,14 @@ leapfrog
jmp xmissile jmp xmissile
EndOfLeapping EndOfLeapping
rts rts
.endp
; ------------------------ ; ------------------------
mirv ; the whole mirv is performed by Flight routine .proc mirv ; the whole mirv is performed by Flight routine
inc FallDown2 inc FallDown2
rts rts
.endp
; ------------------------ ; ------------------------
funkybomb ; .proc funkybomb ;
mwa xtraj+1 xtrajfb mwa xtraj+1 xtrajfb
mwa ytraj+1 ytrajfb mwa ytraj+1 ytrajfb
inc FallDown2 inc FallDown2
@@ -162,8 +168,9 @@ NoExplosionInFunkyBomb
bne FunkyBombLoop bne FunkyBombLoop
mva #0 tracerflag mva #0 tracerflag
rts rts
.endp
; ------------------------ ; ------------------------
deathshead .proc deathshead
inc FallDown2 inc FallDown2
mva #31 ExplosionRadius mva #31 ExplosionRadius
jsr CalculateExplosionRange jsr CalculateExplosionRange
@@ -189,59 +196,69 @@ NoUpperCircle
jsr xmissile jsr xmissile
NoLowerCircle NoLowerCircle
rts rts
.endp
; ------------------------ ; ------------------------
tracer .proc tracer
rts rts
.endp
; ------------------------ ; ------------------------
babyroller .proc babyroller
inc FallDown2 inc FallDown2
mva #11 ExplosionRadius mva #11 ExplosionRadius
jmp xroller jmp xroller
.endp
; ------------------------ ; ------------------------
roller ; .proc roller ;
inc FallDown2 inc FallDown2
mva #21 ExplosionRadius mva #21 ExplosionRadius
jmp xroller jmp xroller
.endp
; ------------------------ ; ------------------------
heavyroller .proc heavyroller
inc FallDown2 inc FallDown2
mva #31 ExplosionRadius mva #31 ExplosionRadius
jmp xroller jmp xroller
.endp
; ------------------------ ; ------------------------
riotbomb .proc riotbomb
inc FallDown2 inc FallDown2
mva #17 ExplosionRadius mva #17 ExplosionRadius
jsr CalculateExplosionRange jsr CalculateExplosionRange
jmp xriotbomb jmp xriotbomb
.endp
; ------------------------ ; ------------------------
heavyriotbomb .proc heavyriotbomb
inc FallDown2 inc FallDown2
mva #29 ExplosionRadius mva #29 ExplosionRadius
jsr CalculateExplosionRange jsr CalculateExplosionRange
jmp xriotbomb jmp xriotbomb
.endp
; ------------------------ ; ------------------------
babydigger .proc babydigger
mva #0 sandhogflag mva #0 sandhogflag
inc FallDown2 inc FallDown2
mva #13 DigLong mva #13 DigLong
mva #1 diggery ; how many branches (-1) mva #1 diggery ; how many branches (-1)
jmp xdigger jmp xdigger
.endp
; ------------------------ ; ------------------------
digger ; .proc digger ;
mva #0 sandhogflag mva #0 sandhogflag
inc FallDown2 inc FallDown2
mva #13 DigLong mva #13 DigLong
mva #3 diggery ; how many branches (-1) mva #3 diggery ; how many branches (-1)
jmp xdigger jmp xdigger
.endp
; ------------------------ ; ------------------------
heavydigger .proc heavydigger
mva #0 sandhogflag mva #0 sandhogflag
inc FallDown2 inc FallDown2
mva #13 DigLong mva #13 DigLong
mva #7 diggery ; how many branches (-1) mva #7 diggery ; how many branches (-1)
jmp xdigger jmp xdigger
.endp
; ------------------------ ; ------------------------
xdigger .proc xdigger
mwa xdraw digstartx mwa xdraw digstartx
mwa ydraw digstarty mwa ydraw digstarty
ldx diggery ldx diggery
@@ -294,7 +311,7 @@ DigRandomize
lda random lda random
and #$87 and #$87
bmi DigUp bmi DigUp
digwdol DigDown
and #$07 and #$07
clc clc
adc digtabyL,x adc digtabyL,x
@@ -302,7 +319,14 @@ digwdol
lda digtabyH,x lda digtabyH,x
adc #$00 adc #$00
sta digtabyH,x sta digtabyH,x
jmp DigCalculateNext ;crashing bug here - if too much added to digtaby, it gets over screenheight and starts writing over random areas
;WARNING! fix for 1 byte screenheight. TODO
lda digtabyL,x
cmp #screenheight
bcc @+ ; branch if less
lda #screenheight-1
sta digtabyL,x
@ jmp DigCalculateNext
DigUp DigUp
and #$07 and #$07
sta temp sta temp
@@ -334,6 +358,7 @@ DigDrawing
bpl DigDrawing bpl DigDrawing
dec:lda DigLong dec:lda DigLong
jpl BranchNotFinished jpl BranchNotFinished
DoNotPutDig
rts rts
DiggerCharacter DiggerCharacter
lda random lda random
@@ -345,55 +370,61 @@ DiggerCharacter
cpw xdraw #(screenwidth-6) cpw xdraw #(screenwidth-6)
bcs DoNotPutDig bcs DoNotPutDig
jmp TypeChar jmp TypeChar
DoNotPutDig .endp
rts
; ------------------------ ; ------------------------
babysandhog .proc babysandhog
mva #8 sandhogflag mva #8 sandhogflag
inc FallDown2 inc FallDown2
mva #13 DigLong mva #13 DigLong
mva #1 diggery ; how many branches (-1) mva #1 diggery ; how many branches (-1)
jmp xdigger jmp xdigger
.endp
; ------------------------ ; ------------------------
sandhog .proc sandhog
mva #8 sandhogflag mva #8 sandhogflag
inc FallDown2 inc FallDown2
mva #13 DigLong mva #13 DigLong
mva #3 diggery ; how many branches (-1) mva #3 diggery ; how many branches (-1)
jmp xdigger jmp xdigger
.endp
; ------------------------ ; ------------------------
heavysandhog .proc heavysandhog
mva #8 sandhogflag mva #8 sandhogflag
inc FallDown2 inc FallDown2
mva #13 DigLong mva #13 DigLong
mva #5 diggery ; how many branches (-1) mva #5 diggery ; how many branches (-1)
jmp xdigger jmp xdigger
.endp
; ------------------------ ; ------------------------
dirtclod .proc dirtclod
inc FallDown2 inc FallDown2
mva #12 ExplosionRadius mva #12 ExplosionRadius
jsr CalculateExplosionRange jsr CalculateExplosionRange
jmp xdirt jmp xdirt
.endp
; ------------------------ ; ------------------------
dirtball .proc dirtball
inc FallDown2 inc FallDown2
mva #22 ExplosionRadius mva #22 ExplosionRadius
jsr CalculateExplosionRange jsr CalculateExplosionRange
jmp xdirt jmp xdirt
.endp
; ------------------------ ; ------------------------
tonofdirt .proc tonofdirt
inc FallDown2 inc FallDown2
mva #31 ExplosionRadius mva #31 ExplosionRadius
jsr CalculateExplosionRange jsr CalculateExplosionRange
jmp xdirt jmp xdirt
.endp
; ------------------------ ; ------------------------
dirtcharge .proc dirtcharge
inc FallDown2 inc FallDown2
mva #61 ExplosionRadius mva #61 ExplosionRadius
jsr CalculateExplosionRange jsr CalculateExplosionRange
jmp ofdirt jmp ofdirt
.endp
; ------------------------ ; ------------------------
laser .proc laser
ldx TankNr ldx TankNr
lda AngleTable,x lda AngleTable,x
tay tay
@@ -447,9 +478,9 @@ laser
jsr DecreaseEnergyX jsr DecreaseEnergyX
LaserMisses LaserMisses
rts rts
.endp
; ----------------- ; -----------------
xmissile ; .proc xmissile ;
; ----------------- ; -----------------
lda #1 lda #1
sta radius sta radius
@@ -533,8 +564,9 @@ EndOfDistanceCheckLoop
txa txa
bne DistanceCheckLoop bne DistanceCheckLoop
rts rts
.endp
; ----------------- ; -----------------
xdirt ; .proc xdirt ;
; ----------------- ; -----------------
lda #1 lda #1
sta radius sta radius
@@ -549,8 +581,9 @@ dirtLoop
cmp ExplosionRadius cmp ExplosionRadius
bne dirtLoop bne dirtLoop
rts rts
.endp
; ----------------- ; -----------------
xriotbomb ; .proc xriotbomb ;
; ----------------- ; -----------------
lda #0 lda #0
sta radius sta radius
@@ -563,10 +596,10 @@ rbombLoop
bne rbombLoop bne rbombLoop
mva #1 color mva #1 color
rts rts
.endp
; ---------------- ; ----------------
xroller ; .proc xroller ;
; now collisions are detected with modified draw routine ; now collisions are detected with modified draw routine
; therefore YDRAW value must be taken from mountaintable ; therefore YDRAW value must be taken from mountaintable
ldy #0 ldy #0
@@ -696,8 +729,9 @@ ExplodeNow
jsr CalculateExplosionRange jsr CalculateExplosionRange
jmp xmissile jmp xmissile
rts rts
.endp
; -------------------------------------------------- ; --------------------------------------------------
ofdirt ; .proc ofdirt ;
; -------------------------------------------------- ; --------------------------------------------------
; makes dirt on xdraw,ydraw position and of ExplosionRadius height ; makes dirt on xdraw,ydraw position and of ExplosionRadius height
mwa xdraw xcircle mwa xdraw xcircle
@@ -742,6 +776,7 @@ EndOfTheDirt
mwa xcircle xdraw mwa xcircle xdraw
mva ycircle ydraw mva ycircle ydraw
rts rts
.endp
;-------------------------------------------------- ;--------------------------------------------------
BeforeFire .proc ;TankNr (byte) BeforeFire .proc ;TankNr (byte)
;-------------------------------------------------- ;--------------------------------------------------
@@ -2108,7 +2143,7 @@ RangesChecked
.endp .endp
;-------------------------------------------------- ;--------------------------------------------------
DecreaseWeaponAfterShoot .proc DecreaseWeaponBeforeShoot .proc
;-------------------------------------------------- ;--------------------------------------------------
ldx TankNr ldx TankNr
lda ActiveWeapon,x lda ActiveWeapon,x