The last part I coded was the sprites"grave stones"that scroll,Ive been busy with porting the balloon game code to z80 assembly"master system" and writing the floor effect in Space Harrier.I know that's disappointing for others that are/did follow the progress,when I'm done I'll come back to these.
call Do_HandleColorRotation
ld hl,ColorPaletteArray
ld de, $C000 ;Color Ram Address
rst DEToVDPControl
ld c, Port_VDPData
call Do_UpdatePaletteColors
jp Label24
;-------------------------------------------------------------
Do_HandleColorRotation:
ld hl,ColorRotationDelay
dec (hl) ;Decrement ColorRotationDelay
ret p
ld a, (ColorRotationDelayC)
ld (hl), a ;ReInit ColorRotationDelay
inc hl
ld a, (hl)
dec (hl) ;Decrement ColorRotationIndex
jp p, +
ld (hl),$07 ;ReInit ColorRotationIndex
+:
and %00000111
ld bc, (ColorsToRotate)
ld l, a
ld h, $00
add hl, hl
ld de,ColorRotationFunctionTable
add hl, de
ld a, (hl)
inc hl
ld h, (hl)
ld l, a
jp (hl)
;-------------------------------------------------------------
ColorRotationFunctionTable:
.dw ColorRotationFunction1
.dw ColorRotationFunction2
.dw ColorRotationFunction3
.dw ColorRotationFunction4
.dw ColorRotationFunction5
.dw ColorRotationFunction6
.dw ColorRotationFunction7
.dw ColorRotationFunction8
;-------------------------------------------------------------
ColorRotationFunction1:
ld hl,ColorRotationArray
ld (hl), b ;DarkGreen
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), c ;Light Green
ret
;-------------------------------------------------------------
ColorRotationFunction2:
ld hl,ColorRotationArray
ld (hl), b ;DarkGreen
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), b ;DarkGreen
ret
;-------------------------------------------------------------
ColorRotationFunction3:
ld hl,ColorRotationArray
ld (hl), b ;DarkGreen
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), b ;DarkGreen
ret
;-------------------------------------------------------------
ColorRotationFunction4:
ld hl,ColorRotationArray
ld (hl), b ;DarkGreen
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), b ;DarkGreen
ret
;-------------------------------------------------------------
ColorRotationFunction5:
ld hl,ColorRotationArray
ld (hl), c ;Light Green
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), b ;DarkGreen
ret
;-------------------------------------------------------------
ColorRotationFunction6:
ld hl,ColorRotationArray
ld (hl), c ;Light Green
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), c ;Light Green
ret
;-------------------------------------------------------------
ColorRotationFunction7:
ld hl,ColorRotationArray
ld (hl), c ;Light Green
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), c ;Light Green
ret
;-------------------------------------------------------------
ColorRotationFunction8:
ld hl,ColorRotationArray
ld (hl), c ;Light Green
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), b ;DarkGreen
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), c ;Light Green
inc hl
ld (hl), c ;Light Green
ret
;-------------------------------------------------------------
.