Browse Source

added Omega Race

pull/5/head
Michael Steil 4 years ago
parent
commit
7e22f8ae13
  1. 429
      OMEGA/chracter
  2. 163
      OMEGA/declare
  3. 15
      OMEGA/omega
  4. 592
      OMEGA/omega001
  5. 749
      OMEGA/omega002
  6. 814
      OMEGA/omega003
  7. 651
      OMEGA/omega004
  8. 146
      OMEGA/omega005
  9. 219
      OMEGA/omega006
  10. 139
      OMEGA/omega007
  11. 1208
      OMEGA/omegachr
  12. 7
      OMEGA/omegaend
  13. 79
      OMEGA/omegaram
  14. 759
      OMEGA/omegatbl
  15. 151
      OMEGA/omegattl
  16. 14
      README.md
  17. 3
      build.sh

429
OMEGA/chracter

@ -0,0 +1,429 @@
.PAGE 'CHRACTER'
*=$F800
;*------------------------------------------------------*
;* CHRACTER PHONTO USED VIC 64 *
;*------------------------------------------------------*
;
;----- SPACE $0
.BYTE %00000000
.BYTE %00000000
.BYTE %00000000
.BYTE %00000000
.BYTE %00000000
.BYTE %00000000
.BYTE %00000000
.BYTE %00000000
;
;----- 0 $1
.BYTE %00111100
.BYTE %01100110
.BYTE %01101110
.BYTE %01110110
.BYTE %01100110
.BYTE %01100110
.BYTE %00111100
.BYTE %00000000
;
;----- 1 $2
.BYTE %00011000
.BYTE %00011000
.BYTE %00111000
.BYTE %00011000
.BYTE %00011000
.BYTE %00011000
.BYTE %01111110
.BYTE %00000000
;
;----- 2 $3
.BYTE %00111100
.BYTE %01100110
.BYTE %00000110
.BYTE %00001100
.BYTE %00110000
.BYTE %01100000
.BYTE %01111110
.BYTE %00000000
;
;----- 3 $4
.BYTE %00111100
.BYTE %01100110
.BYTE %00000110
.BYTE %00011100
.BYTE %00000110
.BYTE %01100110
.BYTE %00111100
.BYTE %00000000
;
;----- 4 $5
.BYTE %00000110
.BYTE %00001110
.BYTE %00011110
.BYTE %01100110
.BYTE %01111111
.BYTE %00000110
.BYTE %00000110
.BYTE %00000000
;
;----- 5 $6
.BYTE %01111110
.BYTE %01100000
.BYTE %01111100
.BYTE %00000110
.BYTE %00000110
.BYTE %01100110
.BYTE %00111100
.BYTE %00000000
;
;----- 6 $7
.BYTE %00111100
.BYTE %01100110
.BYTE %01100000
.BYTE %01111100
.BYTE %01100110
.BYTE %01100110
.BYTE %00111100
.BYTE %00000000
;
;----- 7 $8
.BYTE %01111110
.BYTE %01100110
.BYTE %00001100
.BYTE %00011000
.BYTE %00011000
.BYTE %00011000
.BYTE %00011000
.BYTE %00000000
;
;----- 8 $9
.BYTE %00111100
.BYTE %01100110
.BYTE %01100110
.BYTE %00111100
.BYTE %01100110
.BYTE %01100110
.BYTE %00111100
.BYTE %00000000
;
;----- 9 $A
.BYTE %00111100
.BYTE %01100110
.BYTE %01100110
.BYTE %00111100
.BYTE %00000110
.BYTE %01100110
.BYTE %00111100
.BYTE %00000000
;
;----- A $B
.BYTE %00011000
.BYTE %00111100
.BYTE %01100110
.BYTE %01111110
.BYTE %01100110
.BYTE %01100110
.BYTE %01100110
.BYTE %00000000
;
;----- B $C
.BYTE %01111100
.BYTE %01100110
.BYTE %01100110
.BYTE %01111100
.BYTE %01100110
.BYTE %01100110
.BYTE %01111100
.BYTE %00000000
;
;----- C $D
.BYTE %00111100
.BYTE %01100110
.BYTE %01100000
.BYTE %01100000
.BYTE %01100000
.BYTE %01100110
.BYTE %00111100
.BYTE %00000000
;
;----- D $E
.BYTE %01111000
.BYTE %01101100
.BYTE %01100110
.BYTE %01100110
.BYTE %01100110
.BYTE %01101100
.BYTE %01111000
.BYTE %00000000
;
;----- E $F
.BYTE %01111110
.BYTE %01100000
.BYTE %01100000
.BYTE %01111000
.BYTE %01100000
.BYTE %01100000
.BYTE %01111110
.BYTE %00000000
;
;----- F $10
.BYTE %01111110
.BYTE %01100000
.BYTE %01100000
.BYTE %01111000
.BYTE %01100000
.BYTE %01100000
.BYTE %01100000
.BYTE %00000000
;
;----- G $11
.BYTE %00111100
.BYTE %01100110
.BYTE %01100000
.BYTE %01101110
.BYTE %01100110
.BYTE %01100110
.BYTE %00111100
.BYTE %00000000
;
;----- H $12
.BYTE %01100110
.BYTE %01100110
.BYTE %01100110
.BYTE %01111110
.BYTE %01100110
.BYTE %01100110
.BYTE %01100110
.BYTE %00000000
;
;----- I $13
.BYTE %00111100
.BYTE %00011000
.BYTE %00011000
.BYTE %00011000
.BYTE %00011000
.BYTE %00011000
.BYTE %00111100
.BYTE %00000000
;
;----- J $14
.BYTE %00011110
.BYTE %00001100
.BYTE %00001100
.BYTE %00001100
.BYTE %00001100
.BYTE %01101100
.BYTE %00111000
.BYTE %00000000
;
;----- K $15
.BYTE %01100110
.BYTE %01101100
.BYTE %01111000
.BYTE %01110000
.BYTE %01111000
.BYTE %01101100
.BYTE %01100110
.BYTE %00000000
;
;----- L $16
.BYTE %01100000
.BYTE %01100000
.BYTE %01100000
.BYTE %01100000
.BYTE %01100000
.BYTE %01100000
.BYTE %01111110
.BYTE %00000000
;
;----- M $17
.BYTE %01100011
.BYTE %01110111
.BYTE %01111111
.BYTE %01101011
.BYTE %01100011
.BYTE %01100011
.BYTE %01100011
.BYTE %00000000
;
;----- N $18
.BYTE %01100110
.BYTE %01110110
.BYTE %01111110
.BYTE %01111110
.BYTE %01101110
.BYTE %01100110
.BYTE %01100110
.BYTE %00000000
;
;----- O $19
.BYTE %00111100
.BYTE %01100110
.BYTE %01100110
.BYTE %01100110
.BYTE %01100110
.BYTE %01100110
.BYTE %00111100
.BYTE %00000000
;
;----- P $1A
.BYTE %01111100
.BYTE %01100110
.BYTE %01100110
.BYTE %01111000
.BYTE %01100000
.BYTE %01100000
.BYTE %01100000
.BYTE %00000000
;
;----- Q $1B
.BYTE %00111100
.BYTE %01100110
.BYTE %01100110
.BYTE %01100110
.BYTE %01100110
.BYTE %00111100
.BYTE %00001110
.BYTE %00000000
;
;----- R $1C
.BYTE %01111100
.BYTE %01100110
.BYTE %01100110
.BYTE %01111100
.BYTE %01111000
.BYTE %01101100
.BYTE %01100110
.BYTE %00000000
;
;----- S $1D
.BYTE %00111100
.BYTE %01100110
.BYTE %01100000
.BYTE %00111100
.BYTE %00000110
.BYTE %01100110
.BYTE %00111100
.BYTE %00000000
;
;----- T $1E
.BYTE %01111110
.BYTE %00011000
.BYTE %00011000
.BYTE %00011000
.BYTE %00011000
.BYTE %00011000
.BYTE %00011000
.BYTE %00000000
;
;----- U $1F
.BYTE %01100110
.BYTE %01100110
.BYTE %01100110
.BYTE %01100110
.BYTE %01100110
.BYTE %01100110
.BYTE %00111100
.BYTE %00000000
;
;----- V $20
.BYTE %01100110
.BYTE %01100110
.BYTE %01100110
.BYTE %01100110
.BYTE %01100110
.BYTE %00111100
.BYTE %00011000
.BYTE %00000000
;
;----- W $21
.BYTE %01100011
.BYTE %01100011
.BYTE %01100011
.BYTE %01101011
.BYTE %01111111
.BYTE %01110111
.BYTE %01100011
.BYTE %00000000
;
;----- X $22
.BYTE %01100110
.BYTE %01100110
.BYTE %00111100
.BYTE %00011000
.BYTE %00111100
.BYTE %01100110
.BYTE %01100110
.BYTE %00000000
;
;----- Y $23
.BYTE %01100110
.BYTE %01100110
.BYTE %01100110
.BYTE %00111100
.BYTE %00011000
.BYTE %00011000
.BYTE %00011000
.BYTE %00000000
;
;----- Z $24
.BYTE %01111110
.BYTE %00000110
.BYTE %00001100
.BYTE %00011000
.BYTE %00110000
.BYTE %01100000
.BYTE %01111110
.BYTE %00000000
;
;----- ( $25
.BYTE %00001100
.BYTE %00011000
.BYTE %00110000
.BYTE %00110000
.BYTE %00110000
.BYTE %00011000
.BYTE %00001100
.BYTE %00000000
;
;----- ) $26
.BYTE %00110000
.BYTE %00011000
.BYTE %00001100
.BYTE %00001100
.BYTE %00001100
.BYTE %00011000
.BYTE %00110000
.BYTE %00000000
;
;----- - $27
.BYTE %00000000
.BYTE %00000000
.BYTE %00000000
.BYTE %01111110
.BYTE %00000000
.BYTE %00000000
.BYTE %00000000
.BYTE %00000000
;
;----- $28
.BYTE %00000000
.BYTE %00000000
.BYTE %00011000
.BYTE %00000000
.BYTE %00000000
.BYTE %00011000
.BYTE %00011000
.BYTE %00110000
;
;----- . $29
.BYTE %00000000
.BYTE %00000000
.BYTE %00000000
.BYTE %00000000
.BYTE %00000000
.BYTE %00011000
.BYTE %00011000
.BYTE %00000000
.END

163
OMEGA/declare

@ -0,0 +1,163 @@
.PAGE 'DECLARE'
; MAX STANDARD DECLARE FILE
; *** CONSTANTS ***
SCREEN =$0400 ;START OF SCREEN RAM
VIC =$D000 ;6566 VIDEO INTERFACE CHIP II
SID =$D400 ;6581 SOUND INTERFACE DEVICE
COLRAM =$D800 ;COLOR RAM (1K NIBBLES)
CIA =$DC00 ;6526 COMPLEX INTERFACE ADAPTER
;
; *** 6510 ADDRESSES ***
MDDR =$0000 ;MICROPROCESSOR DATADIRECTION
MOR =$0001 ;MICROPROCESSOR OUTPUT REGISTER
;
; *** VIC II ADDRESSES ***
SP0X =$D000 ;SPRITE 0 X COMPONENT
SP0Y =$D001 ;SPRITE 0 Y COMPONENT
SP1X =$D002
SP1Y =$D003
SP2X =$D004
SP2Y =$D005
SP3X =$D006
SP3Y =$D007
SP4X =$D008
SP4Y =$D009
SP5X =$D00A
SP5Y =$D00B
SP6X =$D00C
SP6Y =$D00D
SP7X =$D00E ;SPRITE 7 X COMPONENT
SP7Y =$D00F ;SPRITE 7 Y COMPONENT
MSIGX =$D010 ;MOST SIGNIFICANT X BIT
SCROLY =$D011 ;SCROLL IN 'Y'(BITS 0-2) AL
; ;EXTENDED COLOR(6)/BIT MAP(5)
RASTER =$D012 ;RASTER LOCATION
LPENX =$D013 ;LIGHT PEN X LATCH
LPENY =$D014 ;LIGHT PEN Y LATCH
SPENA =$D015 ;SPRITE ENABLE (1=SPRITE EN
SCROLX =$D016 ;SCROLL IN 'X'(BITS 0-2) AL
YXPAND =$D017 ;SPRITE EXPAND IN 'Y' (1=EX
VMCSB =$D018 ;VIDEO MATRIX(4-7)/CHARACTE
VICIRQ =$D019 ;IRQ LPEN(3)/SPRITE-SPRITE
; ;SPRITE-BKGO COLLISION(1)/R
IRQMSK =$D01A ;INTERRUPT MASK (SEE VIRQ)
SPBGPR =$D01B ;SPRITE-BKGO PRIORITY (0=SP
SPMC =$D01C ;MULTICOLOR SPRITE SELECT (
XXPAND =$D01D ;SPRITE EXPAND IN 'X' (1=EX
SPSPCL =$D01E ;SPRITE TO SPRITE COLLISION
SPBGCL =$D01F ;SPRITE TO BKGO COLLISION D
EXTCOL =$D020 ;BORDER (EXTERIOR) COLOR
BGCOL0 =$D021 ;BACKGROUND COLOR 0
BGCOL1 =$D022 ;BACKGROUND COLOR 1
BGCOL2 =$D023 ;BACKGROUND COLOR 2
BGCOL3 =$D024 ;BACKGROUND COLOR 3
SPMC0 =$D025 ;SPRITE MULTICOLOR 0
SPMC1 =$D026 ;SPRITE MULTICOLOR 1
SP0COL =$D027 ;SPRITE 0 COLOR
SP1COL =$D028 ;SPRITE 1 COLOR
SP2COL =$D029 ;SPRITE 2 COLOR
SP3COL =$D02A ;SPRITE 3 COLOR
SP4COL =$D02B ;SPRITE 4 COLOR
SP5COL =$D02C ;SPRITE 5 COLOR
SP6COL =$D02D ;SPRITE 6 COLOR
SP7COL =$D02E ;SPRITE 7 COLOR
; *** SID ADDRESSES ***
; THESE SID REGISTERS ARE WRITE-ONLY UNLESS OTHER
; VOICE 1 CONTROL BLOCK **********
FRELO1 =$D400 ;VOICE 1 FREQUENCY LOW
FREHI1 =$D401 ;VOICE 1 FREQUENCY HIGH
PWLO1 =$D402 ;VOICE 1 PULSE WIDTH LOW
PWHI1 =$D403 ;VOICE 1 PULSE WIDTH HIGH
VCREG1 =$D404 ;VOICE 1 CONTPOL REGISTER
; ;NOISE(7)/PULSE(6)/SAW(5)
; ;TEST(3)/RING MOD(2)/SY
ATDLY1 =$D405 ;VOICE 1 ATTACK(4-7)/DE
SUREL =$D406 ;VOICE 1 SUSTAIN(4-7)/R
; VOICE 2 CONTROL BLOCK ******
FRELO2 =$D407 ;VOICE 2 FREQUENCY LOW
FREHI2 =$D408 ;VOICE 2 FREQUENCY HIGH
PWLO2 =$D409 ;VOICE 2 PULSE WIDTH LOW
PWHI2 =$D40A ;VOICE 2 PULSE WIDTH HIGH
VCREG2 =$D40B ;VOICE 2 CONTROL REGISTER
ATDLY2 =$D40C ;VOICE 2 ATTACK(4-7)/DE
SUREL2 =$D40D ;VOICE 2 SUSTAIN(4-7)/R
; VOICE 3 CONTROL BLOCK ******
FRELO3 =$D40E ;VOICE 3 FREQUENCY LOW
FREHI3 =$D40F ;VOICE 3 FREQUENCY HIGH
PWLO3 =$D410 ;VOICE 3 PULSE WIDTH LOW
PWHI3 =$D411 ;VOICE 3 PULSE WIDTH HIGH
VCREG3 =$D412 ;VOICE 3 CONTROL REGISTER
ATDLY3 =$D413 ;VOICE 3 ATTACK(4-7)/DE
SUREL3 =$D414 ;VOICE 3 SUSTAIN(4-7)/R
; FILTER SECTION ****
CUTLO =$D415 ;CUTOFF FREQUENCY LOW
CUTHI =$D416 ;CUTOFF FREQUENCY HIGH
RESON =$D417 ;FILTER RESONANCE(4-7)/S
; ;EXTERNAL(3)/VOICE 3(2)/
SIGVOL =$D418 ;FILTER MODE VOICE 3 OFF
; ;BAND PASS(5)/LOW PASS(4)
; MISC ********** THE FOLLOWING SID REGISTERS
POTX =$D419 ;VALUE OF POTENTIONMETER
POTY =$D41A ;VALUE OF POTENTIONMETER
RANDOM =$D41B ;RANDOM NUMBER/SEQUENCE
ENV3 =$D41C ;VOICE 3 ENVELOPE GENERATER
;
; CIA REGISTERS
CIAPRA =$DC00 ;PERIPHERAL DATA REGISTER
CIAPRB =$DC01 ;PERIPHERAL DATA REGISTER
CIDDRA =$DC02 ;DATA DIRECTION REGISTER A
CIDDRB =$DC03 ;DATA DIRECTION REGISTER B
TIMALO =$DC04 ;TIMER A LOW REGISTER
TIMAHI =$DC05 ;TIMER A HIGH REGISTER
TIMBLO =$DC06 ;TIMER B LOW REGISTER
TIMBHI =$DC07 ;TIMER B HIGH REGISTER
TODTEN =$DC08 ;TIME OF DAY 10THS OF A SECON
TODSEC =$DC09 ;TIME OF DAY SECONDS
TODMIN =$DC0A ;TIME OF DAY MINUTES
TODHRS =$DC0B ;TIME OF DAY HOURS
CIASDR =$DC0C ;SERIAL DATA REGISTER
CIAICR =$DC0D ;INTERRUPT CONTROL REGISTER
CIACRA =$DC0E ;CONTROL REGISTER A
CIACRB =$DC0F ;CONTROL REGISTER B
CIA2 =$DD00 ;UNUSED,NEED INITIALIZE
; COLOR ***
BLACK =$00
WHITE =$01
RED =$02
CYAN =$03
PURPLE =$04
GREEN =$05
BLUE =$06
YELLOW =$07
ORANGE =$08
BROWN =$09
LTRED =$0A
DKGREY =$0B
MDGREY =$0C
LTGREN =$0D
LTBLUE =$0E
LTGREY =$0F
SCRN1 =SCREEN+400+21 ;HEAD OF SCORE
SCRN2 =SCREEN+480+21 ;HEAD OF HI-SCORE
SCRN3 =SCREEN+560+18 ;HEAD OF SHIP DISPLAYED
.END

15
OMEGA/omega

@ -0,0 +1,15 @@
.LIB OMEGATTL
.LIB DECLARE
.LIB OMEGARAM
.LIB OMEGA001
.LIB OMEGA002
.LIB OMEGA003
.LIB OMEGA004
.LIB OMEGA005
.LIB OMEGATBL
.LIB CHRACTER
.LIB OMEGACHR
.LIB OMEGA006
.LIB OMEGA007
.LIB OMEGAEND
.END

592
OMEGA/omega001

@ -0,0 +1,592 @@
.PAGE 'OMEGA001'
;1--------------------------------------------------1
;1 POWER-ON START 1
;1--------------------------------------------------1
*=$E000
START
SEI ;IRQ DISABLE
CLD
LDX #$FF
TXS ;STACK INITIALIZE
IOINIT
;
;----- VIC INITIALIZE
LDX #47
SETVIC
LDA VICTBL-1,X
STA VIC-1,X
DEX
BNE SETVIC
;
;----- SID INITIALIZE
LDX #25
SETSID
LDA SIDTBL-1,X
STA SID-1,X
DEX
BNE SETSID
;
;----- ZERO,2,3 PAGE INITIALIZE
TXA
RAMINI
STA $0002,X
STA $0200,X
STA $0300,X
INX
BNE RAMINI
LDA #BLUE ;SHIP DEFAULT COLOR
STA KOLOR
LDA #WHITE ;BACK DEFAULT COLOR
STA KOLOR+1
LDA #$1F
STA KEYSAV ;INITIALIZE KEY SAVE
;*--------------------------------------------------*
;* ATTRACT MODE *
;*--------------------------------------------------*
ATTRAC
JSR CLRCRT
LDX #<TITLE ;LOW ADDRESS
LDY #>TITLE ;HIGH ADDRESS
JSR CHROUT
LDX #07 ;SET SPRITE COLOR
ATR010
LDA KOLOR
STA SP0COL,X
DEX
BPL ATR010
ATR020
JSR RDFKEY ;READ KEYBORD F1(Y=1),F3(Y=2),F5(Y=3),F7(Y=4)
DEY
BMI ATR030 ;NONE SELECT
CPY #03-1 ;F5 SHIP COLOR CHANGE?
BNE ATR024 ;NO, SELECT F1 OR F3 OR F5
;
;----- SHIP COLOR CHANGE
ATR022 JSR RDFKEY
TYA
BNE ATR022 ;OFF WAIT
INC KOLOR
LDA KOLOR
AND #$0F
STA KOLOR
BPL ATTRAC ;JMP
ATR024 CPY #04-1 ;F7 SCREEN COLOR CHANGE?
BNE ATR050 ;NO, SELECT F1 OR F3
;
;----- SCREEN COLOR CHANGE
ATR026 JSR RDFKEY
TYA
BNE ATR026 ;OFF WAIT
INC KOLOR+1
LDA KOLOR+1
AND #$0F
STA KOLOR+1
STA EXTCOL
STA BGCOL0
BPL ATR020 ;JMP
ATR030
JSR RDPAD ;READ PADDLE
LDY #01
LDA FIRE ;PUSH ?
BEQ ATR020 ;NO
ATR050
STY SCANF ;INPUT SCAN MODE (0:KEY OR JOY 1:PAD)
LDA #03
STA NUMSHP ;SHIP COUNTER = 3
LDA #$1F
STA SIGVOL ;TURN SOUNDS ON
;*--------------------------------------------------*
;* M A I N P R O C E D U R E . *
;*--------------------------------------------------*
MAIN
JSR GMINIT ;GAME INITIALIZE
MAIN10
JSR RDINIT ;ROUND INITIALIZE
;*----- IN GAME LOOP -------------------------------*
;
MAIN20
LDA SCROLY
BPL MAIN20 ;SYNC WITH RASTER
JSR SET7F8 ;USED DBG.
LDA SPSPCL ;GET COLLISION
STA COLLSS
LDA SPBGCL
STA COLLSC
;
;----- USED TIMER COUNTER UP DOWN
INC TIMER1
LDA TIMER1
AND #$3F
BNE MAIN30
DEC EN0WTV ;DEC AT ONE SECOND
DEC EN3WTV ;DEC AT ONE SECOND
MAIN30
INC TIMER2
BNE *+4
INC TIMER3
INC CYCLEP
LDA CYCLEP
AND #$0F
STA CYCLEP ;CYCLE 0 TO F
AND #$07
STA CYCLE ;CYCLE 0 TO 7
;
;----- CALL PARTS SUBROUTINE
JSR SHPMOV ;PLAYER SHIP UPDATE
JSR MSLSET ;MISSLE SETUP
JSR MSLMOV ;MISSLE UPDATE
JSR EN1MOV ;ENEMIES1 UPDATE
JSR EN2MOV ;ENEMIES2 UPDATE
JSR EN3MOV ;ENEMIES3 UPDATE
JSR EN0SET ;ENEMY0 BIGEN
JSR EN1SET ;ENEMY1 BIGEN
JSR EN3SET ;ENEMY3 BIGEN
JSR SOMONE ;FLAME ON-OFF BY TIME
JSR SOUNDM ;SOUND ON-OFF BY TIME
;
;----- CHECK GAME OVER
LDA NUMSHP ;ALL PLAYER SHIPS GONE ?
AND TIMER3 ;AFTER WAIT
BMI GMOVER ;YES
LDA SNDDAT ;CLARE SOUND OFF ?
BNE MAIN40 ;NO
LDA NUMENM ;ALL ENEMIES KILL ?
AND TIMER3 ;AFTER WAIT
BMI MAIN10 ;YES
MAIN40
LDA SPRITA ;ONE SHIP GONE ?
AND TIMER3 ;AFTER WAIT
BMI MAIN10 ;YES
JMP MAIN20 ;IN GAME LOOP
;
;----- CHECK AFTER GAME OVER
GMOVER
LDX #02
GMOV10
LDA LSCORE,X
CMP SCORE,X ;HI-SCORE ?
BCC GMOV20 ;YES
BNE GMOV30 ;NO
DEX
BPL GMOV10
GMOV20
LDA SCORE ;SAVE THE HIGH SCORE
STA LSCORE
LDA SCORE+1
STA LSCORE+1
LDA SCORE+2
STA LSCORE+2
JSR DSPHSC ;DISPLAY HIGH-SCORE
GMOV30
LDA #00
STA SIGVOL ;TURN SOUNDS OFF
INC WATCHR ;CHRACTER DISPLAY WAIT FLAG ON
LDX #<OVERMS ;GAME OVER MESSAGE
LDY #>OVERMS
JSR CHROUT
LDX #$FF
JSR WAIT ;WAIT AFTER DISPLAY
JMP ATTRAC
RTS
;*--------------------------------------------------*
;* CLEAR SCREEN & COLOR *
;*--------------------------------------------------*
CLRCRT
LDX #0
CLR010
LDA KOLOR ;GET SHIP COLOR
STA COLRAM,X
STA COLRAM+$100,X
STA COLRAM+$200,X
STA COLRAM+$300-24,X
LDA #$00 ;SPACE
STA SCREEN,X
STA SCREEN+$100,X
STA SCREEN+$200,X
STA SCREEN+$300-24,X
INX
BNE CLR010
LDA KOLOR+1
STA EXTCOL
STA BGCOL0
STX SPENA ;DISABLE SPRITE
CLR020
LDX #8
CLR030
LDA STABLE-1,X
STA SV07F8-1,X
STA $07F8-1,X
DEX
BNE CLR030
RTS
STABLE .BYTE $08,$09,$0A,$0B,$0C,$0D,$0E,$0F
SET7F8
LDX #8
S7F010
LDA SV07F8-1,X
STA $07F8-1,X
DEX
BNE S7F010
LDX #8
S7F020
LDA SV07F8-1,X
CMP $07F8-1,X
BNE SET7F8
DEX
BNE S7F020
RTS
;*--------------------------------------------------*
;* CHROUT : CHRACTER OUT .X(LOW) .Y(HIGH) *
;*--------------------------------------------------*
CHROUT
STX WK0
STY WK0+1
CHR010
LDY #00
STY WK5 ;OUT CHR. INDEX
LDA (WK0),Y
STA WK2 ;OUT ADDRESS LOW
INY
LDA (WK0),Y
STA WK3 ;OUT ADDRESS HIGH
CHR020
INY
LDA (WK0),Y
CMP #$FF
BEQ CHR090 ;EXIT
CMP #$FE
BEQ CHR030 ;CHANGE OUT ADDRESS
CMP #$FD
BEQ CHR040 ;SELECT NEXT LINE
STY WK4 ;Y SAVE
LDY WK5 ;CHR. OUT INDEX
STA (WK2),Y ;CHR. OUT
INC WK5
LDY WK4 ;Y GET
LDA WATCHR ;DISPLAY WAIT?
BEQ CHR020 ;NO
LDX #10
JSR WAIT
JMP CHR020
CHR030
INY
CLC ;(WK0,WK0+1)=Y+(WK0,WK0+1)
TYA
ADC WK0
STA WK0
LDA WK0+1
ADC #0
STA WK0+1
JMP CHR010
CHR040
CLC
LDA WK2
ADC #40
STA WK2
LDA WK3
ADC #00
STA WK3
LDA #00
STA WK5
BEQ CHR020 ;JMP
CHR090
LDA #00
STA WATCHR
RTS
;*--------------------------------------------------*
;* KEYBORD DATA (F1,F3,F5,F7) READ ROUTINE *
;*--------------------------------------------------*
RDFKEY
LDX #$FF
STX CIDDRA ;SET DATA DIRECTION A
INX ;X=0
STX CIDDRB ;SET DATA DIRECTION B
LDY #01
LDX #$FE ;COLUMN 0
JSR RDROW
CPX #$EF ;ROW 4 F1 ?
BEQ RDF090 ;YES
LDY #$03 ;Y=3
CPX #$BF ;ROW 6 F5 ?
BEQ RDF090 ;YES
LDY #$02 ;Y=2
CPX #$DF ;ROW 5 F3 ?
BEQ RDF090 ;YES
LDY #$04 ;Y=4
CPX #$F7 ;ROW 3 F7 ?
BEQ RDF090 ;YES
LDY #00 ;NONE KEY
RDF090
RTS
;*--------------------------------------------------*
;* KEYBORD DATA (A,S,L,;) READ *
;*--------------------------------------------------*
RDKEY
LDX #$FF
STX CIDDRA ;SET DATA DIRECTION A
INX ;X=0
STX CIDDRB ;SET DATA DIRECTION B
LDA #$1F ;MAKE BIT A-REG SAME JOYSTIK
LDX #$FD ;COLUMN 1
JSR RDROW
CPX #$FB ;ROW 2 A ?
BNE RDK010 ;NO
AND #$FB ;RIGHT BIT ON
BPL RDK090
RDK010 LDX #$FB ;COLUMN 2
JSR RDROW
CPX #$FB ;ROW 2 D ?
BNE RDK020 ;NO
AND #$F7 ;LEFT BIT ON
RDK020 LDX #$DF ;COLUMN 5
JSR RDROW
CPX #$FB ;ROW 2 L ?
BNE RDK030 ;NO
AND #$EF ;FIRE BIT ON
RDK030 LDX #$BF ;COLUMN 6
JSR RDROW
CPX #$FB ;ROW 2 ;?
BNE RDK040 ;NO
AND #$FE ;THRUST BIT ON
RDK040
RDK090 STA KEYSAV
JMP RDJOY ;AFTER SAME JOYSTIK
;*--------------------------------------------------*
;* KEYBORD ROW READ TO (X-REG) *
;*--------------------------------------------------*
RDROW
STX CIAPRA ;COLUMN OUT
RDR010
LDX CIAPRB ;ROW INPUT
CPX CIAPRB
BNE RDR010
RTS
;*--------------------------------------------------*
;* JOYSTIK DATA READ ROUTINE *
;*--------------------------------------------------*
RDJOY
LDX #00
STX CIDDRA
STX CIDDRB ;SET DATA DIRECTION
RDJOY0
LDA CIAPRB
CMP CIAPRB
BNE RDJOY0
AND KEYSAV
AND #$1F
RDJ010
TAY ;SAVE BIT DATA
AND #$10 ;FIRE PRESSED?
BNE RDJ020 ;NO
LDX #$80
BNE RDJ040
RDJ020
BIT FIRE
BPL RDJ030
LDX #$80
STX DFIRE
RDJ030
LDX #00
RDJ040
STX FIRE
LDA CYCLE
AND #$03
BNE RDJ070
LDX #00
TYA
AND #$04 ;LEFT?
BNE RDJ050 ;NO
DEC ROTATE
JMP RDJ060
RDJ050
TYA
AND #$08 ;RIGHT?
BNE RDJ060 ;NO
INC ROTATE
RDJ060
LDA ROTATE
AND #$0F
STA ROTATE
RDJ070
LDX #00
TYA
AND #01 ;UP?
BNE RDJ080 ;NO
LDX #$80 ;YES
RDJ080
STX THRUST
RTS
;*--------------------------------------------------*
;* PADDLE DATA READ ROUTINE *
;*--------------------------------------------------*
RDPAD
LDX #$80
STX CIDDRA ;SET DATA DIRECTION
LDX #$00
STX CIDDRB
RDPAD0
LDX #16
LDA POTX
RDP010
CMP PADTBL,X
BCS RDP020 ;IT IS GREATER
DEX
BPL RDP010
BMI RDP030
RDP020
DEX
TXA
EOR #$FF
AND #$0F ;MASK OFF EXTRA BIT
STA ROTATE
RDP030
LDA CIAPRB
AND #$04 ;FIRE PRESSED?
BEQ RDP060 ;YES
LDA #$00 ;BUTTON ISN'T PRESSED
STA THRUST ;JUST IN CASE
LDA FIRE ;WAS BUTTON PRESSED BEFORE?
BEQ RDP040 ;NO
LDA FTIME
CMP CYCLEP ;WAS IT WITHIN THE LIMITS
BEQ RDP050 ;NO
LDA #$80 ;IT WAS A FIRE COMMAND
STA DFIRE
RDP040
LDA CYCLEP ;RESET THINGS NOW
STA FTIME
RDP050
LDA #$00
STA FIRE
BEQ RDP090 ;EXIT
RDP060
LDA THRUST ;IF THRUSTING, KEEP GOING
BMI RDP090 ;EXIT
LDA FIRE ;WAS BUTTIN PUSHED BEFORE?
BEQ RDP070 ;NO
LDA FTIME
CMP CYCLEP ;WAS IT HELD DOWN LONG ENOUGH
BNE RDP090 ;NOT YET
LDA #$00
STA FIRE
LDA #$80
STA FTIME
STA THRUST
BNE RDP090 ;EXIT
RDP070
LDA #$80
STA FIRE
LDA CYCLEP
STA FTIME
RDP090
RTS
PADTBL
.BYTE 0,15,30,45,60,75,90,105
.BYTE 120,135,150,165,180,195,210,225,240
;*--------------------------------------------------*
;* WAIT A FEW SEC. (16MS * X) *
;*--------------------------------------------------*
WAIT
LDA SCROLY ;GET SYNC
BPL WAIT
WAIT10
LDA SCROLY ;
BMI WAIT10
DEX
BNE WAIT
RTS
.END

749
OMEGA/omega002

@ -0,0 +1,749 @@
.PAGE 'OMEGA002'
;*--------------------------------------------------*
;* GAME START INITIALIZE *
;*--------------------------------------------------*
GMINIT
LDA #00 ;SCORE CLEAR
STA SCORE
STA SCORE+1
STA SCORE+2
STA XTRA ;EXTRA SHIP FLAG OFF
STA ROUND ;ROUND NUMBER CLEAR
LDX #8-1 ;SET ENEMIES3 TABLE
LDA #$FF
GMI010
STA ENMY3A,X
DEX
BPL GMI010
STA NUMENM ;ENEMY ALL DONE
RTS
;*--------------------------------------------------*
;* ROUND INITIALIZE *
;*--------------------------------------------------*
RDINIT
LDA NUMENM ;ENEMY ALL DONE?
BPL *+4 ;NO
INC ROUND ;NEXT ROUND NUMBER
LDX ROUND
CPX #$03 ;PAST 3 ROUND ?
BCC *+4 ;NO
LDX #$04
LDA ENMCNT-1,X ;GET NUMBER OF ENEMIES
STA NUMENM ;SET IT
LDA EN0TM0-1,X ;GET ENEMY0 BIGEN TIME
STA EN0WTV ;SET IT
LDA EN0TIM-1,X ;GET ENEMY0 RESET INTERVAL TIME
STA EN0WTF ;SET IT
LDA EN1TIM-1,X ;GET ENEMY1 MOVE WAIT TIME
STA EN1WTF ;SET IT
LDA EN2TIM-1,X ;GET ENEMY2 MOVE WAIT TIME
STA EN2WTF ;SET IT
LDA EN3TIM-1,X ;GET ENEMY3 DISPLAY TIME
STA EN3WTF ;SET IT
LDA #6
STA EN3WTV ;SET ENEMY3 BIGEN TIME
LDA #01
STA EN1WTV ;
STA EN2WTV ;
LDA RANDOM ;GET RANDOM VALUE
AND #$01
STA ENROTE ;SET ENEMIES ROTATION
ASL A ;SET ENYMIES 2 TABLE
TAY
LDA EN2TB,Y
STA WK0
LDA EN2TB+1,Y
STA WK1
LDY #10
RDI010
LDA (WK0),Y
STA ENMY2A,Y
DEY
BPL RDI010
LDY #10 ;ERASE ENYMIES BY ROUND NO.
LDA #$FF
RDI020
CPX #4
BEQ RDI030
STA ENMY2A,Y
DEY
STA ENMY2A,Y
DEY
INX
BNE RDI020 ;JMP
RDI030
LDY #00 ;SET ENEMIES 2 TABLE
RDI040
LDA EN2BGN,Y
STA EN2YP,Y ;EN2YP(11),EN2XPL(11),EN2XPH(11)
INY
CPY #11
BNE RDI040
RDI042
LDA EN2BGN,Y
STA EN2XPL-11,Y
INY
CPY #22
BNE RDI042
RDI044
LDA EN2BGN,Y
STA EN2XPH-22,Y
INY
CPY #33
BNE RDI044
;
;----- OFF ENEMY3 DISPLAY BIT
LDX #8-1
RDI046
LDA ENMY3A,X
AND #$7F
STA ENMY3A,X
DEX
BPL RDI046
;
;----- KILL ENEMY3 AROUND SHIP
LDX #8-1
RDI048
LDA EN3YP,X ;GET ENEMY3 Y POINT
CMP #82 ;<82 ?
BCC RDI054 ;YES
CMP #106 ;>=106 ?
BCS RDI054 ;YES
LDA EN3XPH,X
BNE RDI050 ;>255
LDA EN3XPL,X
CMP #55 ;<55 ?
BCC RDI054 ;YES
CMP #79 ;>=79 ?
BCS RDI054 ;YES
BCC RDI052
RDI050
LDA EN3XPL,X
CMP #24 ;>=24 ?
BCS RDI054 ;YES
RDI052
LDA #$FF
STA ENMY3A,X ;KILL ENEMY3
RDI054
DEX
BPL RDI048
;
;----- KILL ALL SPRITE FUNCTION
LDY #08-1
LDA #$FF
RDI058
STA SPRITA,Y
DEY
BPL RDI058
LDY #24-1
LDA #01
RDI060
STA SPRITB,Y
DEY
BPL RDI060
;
;----- SET SPRITE FUNCTION
LDA #00
STA SPRITA+0 ;SET SPRITE 0 SHIP
LDY #00
STY SPRITA+5 ;SET SPRITE 5 ENEMY1A
INY
STY SPRITA+6 ;SET SPRITE 6 ENEMY1B
LDA EN1WTF ;GET ENEMY1 RESET INTERVAL TIME
STA SPRITC+5 ;SET IT TO SPRITE 5
STA SPRITC+6 ;SET IT TO SPRITE 6
LDA ENROTE
BNE RDI070
LDA #02
STA SPRITD+5
LDA #07
STA SPRITD+6
LDA #55
STA SP0X
LDA #00
BEQ RDI080 ;JMP
RDI070
LDA #$0E
STA SPRITD+5
LDA #$09
STA SPRITD+6
LDA #47
STA SP0X
LDA MASKS+0
RDI080
STA MSIGX
LDA #82
STA SP0Y
LDA #199
STA SP5X
LDA #201
STA SP5Y
LDA #159
STA SP6X
LDA #185
STA SP6Y
LDA #$00 ;FLAGS INITIALIZE
STA FIRE
STA DFIRE
STA THRUST
STA FTIME
STA EN2IDX
STA EMARGE
STA TIMER3
STA ACSSEL
STA KILLSP
LDX #$00
RDI090
STA $200,X
STA $300,X
INX
BNE RDI090
JSR CLRCRT ;CLEAR SCREEN
LDX #<GMSCRN ;FLAME DISPLAY
LDY #>GMSCRN
JSR CHROUT
JSR DSPSCR ;DISPLAY SCORE
JSR DSPHSC ;DISPLAY HIGH SCORE
JSR DSPSHP ;DISPLAY SHIP IN FLAME
LDA #%01100001
STA SPENA
RTS
;*--------------------------------------------------*
;* DISPLAY SCORE *
;*--------------------------------------------------*
DSPSCR
LDX #<SCRN1
LDY #>SCRN1
STX WK0
STY WK1
LDX #0
LDY #5
SCO10
LDA SCORE,X
AND #$0F
STA WK2
INC WK2
LDA WK2
STA (WK0),Y
DEY
LDA SCORE,X
LSR A
LSR A
LSR A
LSR A
STA WK2
INC WK2
LDA WK2
STA (WK0),Y
INX
DEY
BPL SCO10
RTS
;*--------------------------------------------------*
;* DISPLAY HI-SCORE *
;*--------------------------------------------------*
DSPHSC
LDX #<SCRN2
LDY #>SCRN2
STX WK0
STY WK1
LDX #0
LDY #5
HSC10
LDA LSCORE,X
AND #$0F
STA WK2
INC WK2
LDA WK2
STA (WK0),Y
DEY
LDA LSCORE,X
LSR A
LSR A
LSR A
LSR A
STA WK2
INC WK2
LDA WK2
STA (WK0),Y
INX
DEY
BPL HSC10
RTS
;*--------------------------------------------------*
;* DISPLAY SHIP IN FLAME *
;*--------------------------------------------------*
DSPSHP
LDX #<SCRN3
LDY #>SCRN3
STX WK0
STY WK1
LDA #6
STA WK3
LDY #0
LDA #$42
LDX NUMSHP
BNE DSHP20
DSHP10
LDA #$00
DSHP20
STA (WK0),Y
INY
INY
DEC WK3
BEQ DSHP90
DEX
BNE DSHP20
BEQ DSHP10
DSHP90
RTS
;*--------------------------------------------------*
;* SOMETHING ON-OFF BY TIME *
;*--------------------------------------------------*
;----- FLASH FLAME CONTROL
SOMONE
LDX #$07
SOM010
LDA LINTIM,X
BEQ SOM020
DEC LINTIM,X
LDA LINTIM,X
BEQ SOM050 ;LINE OFF
CMP #$05
BEQ SOM040 ;LINE HALF OFF
CMP #$0A
BEQ SOM030 ;LINE ON
SOM020
DEX
BPL SOM010
BMI SOM100 ;JMP
SOM030
TXA
ASL A
TAY
LDA ONTB,Y
TAX
LDA ONTB+1,Y
TAY
JMP SOM060
SOM040
TXA
ASL A
TAY
LDA HOFTB,Y
TAX
LDA HOFTB+1,Y
TAY
JMP SOM060
SOM050
TXA
ASL A
TAY
LDA OFFTB,Y
TAX
LDA OFFTB+1,Y
TAY
SOM060
JSR CHROUT
;
;----- CALL BOMB SUBROUTINE
SOM100
JSR BMBSPR
;
;----- WAIT TIMER RENEW
LDA NUMSHP
ORA NUMENM
ORA SPRITA
BMI SOM200
LDA TIMER3
AND #$7F
STA TIMER3
SOM200
RTS
;*--------------------------------------------------*
;* ENEMISE 2 MOVE *
;*--------------------------------------------------*
EN2MOV
DEC EN2WTV ;DISPLAY TIME ?
BEQ *+5 ;YES
JMP E2M090 ;EXIT
LDA EN2WTF
STA EN2WTV ;RESET INTERVAL TIMER
INC EN2IDX ;ENEMY 2 DISPLAY INDEX
LDX EN2IDX
CPX #11
BCC *+4
LDX #00
STX EN2IDX
LDA ENMY2A,X
CMP #$FF
BNE *+5
JMP E2M090 ;NONE EXIST
LDA ENMY2A,X ;GET ENEMISE 2 DIRECTION
AND #$C0 ;RIGHT?
BNE E2M010 ;NO
E2M004
INC EN2XPL,X ;INC X POINT L
BNE *+4
INC EN2XPH,X ;INC X POINT H
LDA EN2XPL,X
AND #$07 ;NEW CHRACTER NUMBER?
BNE E2M08A ;NO, GO TO DISPLAY
DEC ENMY2A,X ;DEC CHRACTER NUMBER
LDA ENMY2A,X
AND #$3F ;CHRACTER NUMBER ZERO?
BNE E2M08A ;NO, GO TO DISPLAY
LDA EN2TB3,X ;GET Y SPAN
ORA #$40 ;OR UP MODE
LDY ENROTE ;LEFT ROTATE?
BEQ *+4 ;YES
ORA #$80 ;OR DOWN MODE
STA ENMY2A,X ;SET NEW MOVE VALUE
E2M08A
JMP E2M080 ;GO TO DISPLAY
E2M010
CMP #$80 ;LEFT?
BNE E2M020 ;NO
E2M014
DEC EN2XPL,X ;DEC X POINT L
LDA EN2XPL,X
CMP #$FF
BNE *+4
DEC EN2XPH,X ;DEC X POINT H
AND #$07 ;NEW CHRACTER NUMBER?
BNE E2M080 ;NO, GO TO DISPLAY
DEC ENMY2A,X ;DEC CHRACTER NUMBER
LDA ENMY2A,X
AND #$3F ;CHRACTER NUMBER ZERO?
BNE E2M080 ;NO, GO TO DISPLAY
LDA EN2TB3,X ;GET Y SPAN
ORA #$40 ;OR UP MODE
LDY ENROTE ;LEFT ROTATE?
BNE *+4 ;NO
ORA #$80 ;OR DOWN MODE
STA ENMY2A,X ;SET NEW MOVE VALUE
BNE E2M080 ;JMP DISPLAY
E2M020
CMP #$40 ;UP?
BNE E2M030 ;NO
DEC EN2YP,X ;DEC Y POINT
LDA EN2YP,X
AND #$07 ;NEW CHRACTER NUMBER?
BNE E2M080 ;NO, GO TO DISPLAY
DEC ENMY2A,X ;DEC CHRACTER NUMBER
LDA ENMY2A,X
AND #$3F ;CHRACTER NUMBER ZERO?
BNE E2M080 ;NO, GO TO DISPLAY
LDA EN2TB2,X ;GET X SPAN
LDY ENROTE ;LEFT ROTATE?
BNE *+4
ORA #$80 ;OR LEFT MODE
STA ENMY2A,X ;SET NEW MOVE VALUE
BNE E2M080 ;JMP DISPLAY
E2M030
INC EN2YP,X ;INC Y POINTER
LDA EN2YP,X
AND #$07 ;NEW CHRACTER NUMBER?
BNE E2M080 ;NO, GO TO DISPLAY
DEC ENMY2A,X
LDA ENMY2A,X
AND #$3F ;CHRACTER NUMBER ZERO?
BNE E2M080 ;NO, GO TO DISPLAY
LDA EN2TB2,X ;GET X SPAN
LDY ENROTE ;LEFT ROTATE?
BEQ *+4 ;YES
ORA #$80 ;OR LEFT MODE
STA ENMY2A,X ;SET NEW MOVE VALUE
E2M080
JSR EN2DSP
E2M090
RTS
;*--------------------------------------------------*
;* DISPLAY ENEMY 2 *
;* INPUT X-REG DISPLAY ENEMY INDEX *
;*--------------------------------------------------*
EN2DSP
JSR BITCHR ;GET SCREEN ADDRESS (WK0,WK1)
LDA ENMY2A,X
AND #$40 ;UP DOWN MODE ?
BNE E2D010 ;YES
;
;----- LEFT RIGHT MODE
LDA EN2XPL,X
AND #$07
STA WK2
ASL A
ASL A
ADC WK2
ADC WK2 ;*6
ADC #E2XPTN ;PATTERN START NUMBER
TAY
STY WORK+$02
INY
STY WORK+$03
INY
STY WORK+$04
INY
STY WORK+$08
INY
STY WORK+$09
INY
STY WORK+$0A
LDY #$FE
STY WORK+$05
INY
STY WORK+$0B
CLC
LDA WK0
STA WORK+$00
ADC #40
STA WORK+$06
LDA WK1
STA WORK+$01
ADC #00
STA WORK+$07
JMP E2D020
;
;----- UP DOWN MODE
E2D010
LDA EN2YP,X
AND #$07
STA WK2
ASL A
ASL A
ADC WK2
ADC WK2 ;*6
ADC #E2YPTN ;PATTERN START NUMBER
TAY
STY WORK+$02
INY
STY WORK+$03
INY
STY WORK+$07
INY
STY WORK+$08
INY
STY WORK+$0C
INY
STY WORK+$0D
LDY #$FE
STY WORK+$04
STY WORK+$09
INY
STY WORK+$0E
CLC
LDA WK0
STA WORK+$00
ADC #40
STA WORK+$05
LDA WK1
STA WORK+$01
ADC #00
STA WORK+$06
CLC
LDA WK0
ADC #80
STA WORK+$0A
LDA WK1
ADC #00
STA WORK+$0B
E2D020
LDX #<WORK
LDY #>WORK
JSR CHROUT
RTS
E2XPTN = $44
E2YPTN = $74
;*--------------------------------------------------*
;* ENEMIES 3 DISPLAY CHECK *
;*--------------------------------------------------*
E3APTN = $A4
E3BPTN = $A5
EN3MOV
CLC
LDA CYCLE ;DATA=0---7
ADC #$0B
TAX
LDA ENMY2A,X
CMP #$FF ;ENEMY3 LIVE?
BEQ E3M090 ;NO
; ;ALREADY DISPLAY?
BPL E3M020 ;NO
JSR BITCHR ;GET SCREEN ADDRESS (WK0,WK1)
LDY #00
LDA (WK0),Y ;ENEMY3 LIVE?
CMP #E3APTN ;ENEMY3 CHARACTER NUMBER A?
BEQ E3M090 ;YES
CMP #E3BPTN ;ENEMY3 CHARACTER NUMBER B?
BEQ E3M090 ;YES
E3M010
LDA #$FF
STA ENMY2A,X ;LIVE MODE OFF
BMI E3M090 ;JMP EXIT
;
;----- DISPLAY ENEMY3
E3M020
JSR BITCHR ;GET SCREEN ADDRESS (WK0,WK1)
LDY #00
LDA (WK0),Y
CMP #E3APTN
BEQ E3M010
CMP #E3BPTN
BEQ E3M010
LDA WK0
STA WORK+$00
LDA WK1
STA WORK+$01
LDA ENMY2A,X
ORA #$80
STA ENMY2A,X ;SET DISPLAY BIT
AND #$01
CLC
ADC #E3APTN ;ENEMY3 CHARACTER NUMBER
STA WORK+$02
LDA #$FF
STA WORK+$03
LDX #<WORK
LDY #>WORK
JSR CHROUT
E3M090
RTS
;*--------------------------------------------------*
;* BIT MAP ADDRESS CHANGE TO SCREEN ADDRESS *
;*--------------------------------------------------*
BITCHR
LDA #<SCREEN
STA WK0
LDA #>SCREEN
STA WK1
LDA EN2YP,X ;GET Y POINTER
SEC
SBC #48
AND #$F8 ;CUT OFF < 8
STA WK2
CLC ;POINTER/8*40=POINTER/8*8*5
ADC WK0
STA WK0
LDA WK1
ADC #00
STA WK1
LDA #00
ASL WK2
ROL A
ASL WK2
ROL A
CLC
ADC WK1
STA WK1
CLC
LDA WK2
ADC WK0
STA WK0
LDA WK1
ADC #00
STA WK1 ;(WK0,WK1)=(WK0,WK1)+(YPOINT-48)/8*40
LDA EN2XPH,X ;X POINT HIGH
LSR A ;CARRY = X POINT HIGH
LDA EN2XPL,X ;X POINT LOW
ROR A
LSR A
LSR A ;/8
SEC
SBC #03
CLC
ADC WK0
STA WK0
LDA WK1
ADC #00
STA WK1 ;(WK0,WK1)=(WK0,WK1)+(XPOINT-24)/8
RTS
.END

814
OMEGA/omega003

@ -0,0 +1,814 @@
.PAGE 'OMEGA003'
;*--------------------------------------------------*
;* ENEMIES1 MOVE BY SPRITE MODE (SP5,SP6) *
;*--------------------------------------------------*
EN1MOV
LDX #05 ;FIRST ENEMY1 NUMBER
JSR SPRMOV ;SPRITE POINTER UPDATE
LDX #05
JSR SPRGEN ;SPRITE PATTERN GENERATE
LDX #06 ;SECOND ENEMY1 NUMBER
JSR SPRMOV ;SPRITE POINTER UPDATE
LDX #06
JSR SPRGEN
RTS
;*--------------------------------------------------*
;* SPRITE PATTERN GENERATE *
;*--------------------------------------------------*
SPRGEN
LDY SPRITA,X ;LIVE ?
BMI SPG090 ;NO
LDA WK4 ;TAKE MOTION ?
BMI SPG090 ;NO
CPY #$02 ;MODE >=2 ?
BCS SPG010 ;YES
INY ;PATTERN MODE CHANGE
TYA
AND #$01
STA SPRITA,X ;0-1,1-0
TAY
JSR SETEN1 ;SPRITE PATTERN SET BY Y-REG
JMP SPG090 ;EXIT
SPG010
CPY #$05 ;MODE >=5 ?
BCS SPG020 ;YES
INY
CPY #$05
BNE *+4
LDY #$02
STY SPRITA,X ;2-3,3-4,4-2
JSR SETEN0 ;SPRITE PATTERN SET BY Y-REG
SPG020
SPG090
RTS
;
;----- ENEMY1 DISPLAY
SETEN1
LDA #$FD
STA WK1
STA WK3
LDA #$60
CPY #00
BNE *+4
LDA #$80
STA WK0
CLC
ADC #$10
STA WK2
LDA #$03
STA WK5
LDA #$40
CPX #05
BEQ *+4
LDA #$80
STA WK4
LDY #00
LDX #16
SE1010
LDA (WK0),Y
STA (WK4),Y
INC WK4
LDA (WK2),Y
STA (WK4),Y
INC WK4
INC WK4
INC WK0
INC WK2
DEX
BNE SE1010
RTS
;
;----- ENEMY0 DISPLAY
SETEN0
LDA #$FD
STA WK1
DEY
DEY ;0,1,2
TYA
ASL A
ASL A
ASL A
ASL A ;0,16,32
CLC
ADC #$30
STA WK0
TXA
ASL A
TAY
LDA SPRTBL,Y
ORA #$0C
STA WK4
LDA SPRTBL+1,Y
STA WK5
LDY #00
LDX #08
SE0010
LDA (WK0),Y
STA (WK4),Y
INC WK0
INC WK4
LDA (WK0),Y
STA (WK4),Y
INC WK0
INC WK4
INC WK4
DEX
BNE SE0010
RTS
;*--------------------------------------------------*
;* SPRITE POINTER MOVE *
;* INPUT X-REG SPRITE NUMBER *
;*--------------------------------------------------*
SPRMOV
LDA #$FF
STA WK4 ;MOTIN FLAG OFF
STA WK5 ;LIMIT FLAG OFF
LDA SPRITA,X ;LIVE ?
BPL *+3 ;YES
RTS ;NOT LIVE RTS
DEC SPRITB,X ;INTERVAL TIMER ZERO?
BEQ *+3 ;YES
RTS ;NOT MOVE TIME RTS
LDA SPRITC,X ;GET FIXED TIMER
STA SPRITB,X ;SET INTERVAL TIMER
INC WK4 ;MOTION FLAG ON
;
;----- MOVE BY DIRECTION
LDA SPRITD,X ;GET DIRECTION
TAY
LDA WALKY,Y ;GET MOVE DISTANCE
STA WK0 ;SAVE
LDA WALKX,Y ;GET X MOVE DISTANCE
STA WK1 ;SAVE
TXA
ASL A
TAY ;Y=INDEX OF VIC-SPRITE
CLC
LDA VIC+1,Y
ADC WK0
STA VIC+1,Y ;RESET NEW Y POINTER
STA WK0 ;SAVE Y POINTER TO WK0
CLC
LDA VIC,Y
ADC WK1
STA VIC,Y ;RESET NEW X POINTER LOW
STA WK1 ;SAVE X POINTER TO WK1
CMP #$FE ;>=$FE?
BCC SPM010 ;NO
LDA MASKS,X ;GET SPRITE X MSB MASK
EOR #$FF
AND MSIGX ;OFF X POINTER MSB
BCS SPM020 ;JMP
SPM010
CMP #$03 ;<$03?
BCS SPM030 ;NO
LDA MASKS,X ;GET SPRITE X MSB MASK
ORA MSIGX ;ON X POINTER MSB
SPM020
STA MSIGX ;SET X POINTER MSB OF VIC
SPM030
LDA MSIGX
AND MASKS,X
STA WK2 ;SAVE X POINTER MSB TO WK2
;
;----- CHECK LIMIT OF SCREEN UP-DOWN
LDA #$FF
STA WK3 ;FRAME FLASH OFF
LDA WK0 ;GET Y POINTER
CMP #54 ;>= 54?
BCS SPM040 ;YES
LDA #55
STA VIC+1,Y
INC WK3 ;FLASH FRAME NUMBER = 0
BEQ SPM050 ;JMP
SPM040
CMP #230 ;Y POINTER < 230 ?
BCC SPM070 ;YES
LDA #229
STA VIC+1,Y
LDA #04
STA WK3 ;FLASH FRAME NUMBER = 4
SPM050
LDA WK2 ;X MSB ON?
BNE SPM060 ;YES
LDA WK1 ;GET X POINTER
CMP #170 ;<170?
BCC SPM090 ;YES GO TO CHANGE DIRECTION UP-DOWN
SPM060
INC WK3 ;FLASH FRAME NUMBER = 1 OR 5
JMP SPM090 ;GO TO CHANGE DIRECTION UP-DOWN
SPM070
LDA WK2 ;GET X MSB ON ?
BNE SPM100 ;YES
LDA WK1 ;GET X POINTER
CMP #101 ;<101 ?
BCC SPM100 ;YES
CMP #248 ;>=248 ?
BCS SPM100 ;YES
LDA WK0 ;GET Y POINTER
CMP #174 ;Y POINTER = 174?
BEQ SPM082 ;YES
CMP #173 ;Y = 173?
BEQ SPM082 ;YES
CMP #110 ;Y = 110?
BEQ SPM080 ;YES
CMP #111 ;Y = 111?
BNE SPM100 ;NO
SPM080
LDA #109 ;RESET Y POINT
BNE SPM084 ;JMP
SPM082
LDA #175 ;RESET Y POINT
SPM084
STA VIC+1,Y
SPM090
SEC ;CHANGE DIRECTION OF SPRITE
LDA #08 ;0-8,1-7,2-6,3-5,4-4,5-3,6-2,7-1
SBC SPRITD,X ;8-0,9-F,A-E,B-D,C-C,D-B,E-A,F-9
AND #$0F ;
STA SPRITD,X ;SET NEW DIRECTION
BPL SPM200 ;JMP FRAME ON
;
;----- CHECK LIMIT OF SCREEN LEFT-RIGHT
SPM100
LDA WK2 ;X POINTER MSB ON?
BEQ SPM110 ;ON
LDA WK1 ;GET X POINTER
CMP #69 ;>=69?
BCC SPM130 ;NO GO TO EXIT
LDA #68
STA VIC,Y
LDA #02
STA WK3 ;FLASH FRAME NUMBER = 2
BPL SPM120 ;JMP SELECT FLASH FRAME
SPM110
LDA WK1 ;GET X POINTER
CMP #30 ;<30?
BCS SPM130 ;NO
LDA #31
STA VIC,Y
LDA #06
STA WK3 ;FLASH FRAME NUMBER = 6
SPM120
LDA WK0 ;GET Y POINTER
CMP #142 ;< 142?
BCC SPM150 ;YES GO TO CHANGE DIRECTION
INC WK3 ;FLASH FRAME NUMBER = 3 OR 7
BCS SPM150 ;JMP GO TO CHANGE DIRECTION
SPM130
LDA WK0 ;GET Y POINTER
CMP #110 ;<110 ?
BCC SPM900 ;YES
CMP #175 ;>=175 ?
BCS SPM900 ;YES
LDA WK1 ;GET X POINTER
CMP #101 ;X = 101?
BEQ SPM142 ;YES
CMP #102 ;X = 102?
BEQ SPM142 ;YES
CMP #247 ;X = 247?
BEQ SPM140 ;YES
CMP #248 ;X = 248?
BNE SPM900 ;NO GO TO EXIT
SPM140
LDA #249 ;RESET X POINTER
BNE SPM144 ;JMP
SPM142
LDA #100 ;RESET X POINTER
SPM144
STA VIC,Y
SPM150
SEC ;CHANGE DIRECTION OF SPRITE
LDA #00 ;0-0,1-F,2-E,3-D,4-C,5-B,6-A,7-9
SBC SPRITD,X ;8-8,9-7,A-6,B-5,C-4,D-3,E-2,F-1
AND #$0F
STA SPRITD,X
;
;----- FLASH FRAME ON
SPM200
CPX #00
BNE SPM210
LDA #$04
STA KILLSP ;WAIT TIMER OF SHIP CONTROL
SPM210
INC WK5 ;LIMIT FLAG ON
LDA WK3 ;GET FLASH FRAME EXIST?
BMI SPM900 ;NO
TAY
LDA #$0B
STA LINTIM,Y ;TURN ON FRAME
SPM900
RTS
;*--------------------------------------------------*
;* ENEMY0 SET FROM ENEMY1 DATA *
;*--------------------------------------------------*
EN0SET
LDA EN0WTV ;SET TIME OK ?
BNE E0S900 ;NO EXIT
LDA EN0WTF ;GET ENEMY0 SET TIME
STA EN0WTV ;SET DEC TIMER
LDX #05
LDA #01
CMP SPRITA,X ;ENEMY1A LIVE ?
BCS E0S010 ;YES 0 OR 1
INX
CMP SPRITA,X ;ENEMY1B LIVE ?
BCS E0S020 ;YES 0 OR 1
BCC E0S900 ;NO EXIT
E0S010
LDA SPRITA+1,X ;ALREDY ENEMY0 LIVE ?
JMP E0S030
E0S020
LDA SPRITA-1,X
E0S030
CMP #02 ;<2 ?
BCC E0S040 ;YES 0 OR 1
CMP #05 ;>=5 ?
BCS E0S040 ;YES
LDA ROUND
CMP #07 ;ROUND < 7 ?
BCC E0S900 ;YES
E0S040
LDA #02
STA SPRITA,X ;SET ENEMY0
LDA #01
STA SPRITB,X
STA SPRITC,X
JSR SPRCLR ;SPRITE PATTERN CLEAR
E0S900
RTS
;*---------------------------------------------------*
;* SPRITE PATTERN CLEAR BY X-REG. *
;*---------------------------------------------------*
SPRCLR
STX WK0 ;X=SPRITE NUMBER 0---7
LDA #00
STA WK1
LDY #05
SPC010
ASL WK0
ROL WK1
DEY
BPL SPC010
INC WK1
INC WK1
LDY #63
LDA #00
SPC020
STA (WK0),Y
DEY
BPL SPC020
RTS
;*--------------------------------------------------*
;* ENEMY1 SET *
;*--------------------------------------------------*
EN1SET
LDX #05
LDA #$FF
CMP SPRITA,X ;ENEMY1A DONE ?
BEQ E1S010 ;YES
INX
CMP SPRITA,X ;ENEMY1B DONE ?
BNE E1S900 ;NO EXIT
E1S010
LDY #11-1 ;LOOK ENEMY2 LIVE TABLE
E1S020
LDA ENMY2A,Y ;LIVE ?
CMP #$FF
BNE E1S030 ;YES
DEY
BPL E1S020
BMI E1S900 ;EXIT
;
;----- CHANGE ENEMY2 TO ENEMY1
E1S030
TXA
ASL A
TAX
LDA #$FF
STA ENMY2A,Y ;KILL ENEMY2
LDA EN2YP,Y ;GET ENEMY2 Y POINT
STA SP0Y,X ;SET ENEMY1 Y POINT
LDA EN2XPL,Y ;GET ENEMY2 X POINT L
STA SP0X,X ;SET ENEMY1 X POINT
TXA
LSR A
TAX
LDA EN2XPH,Y ;GET ENEMY2 X POINT H
BEQ E1S040
LDA MASKS,X
ORA MSIGX
BNE E1S050
E1S040
LDA MASKS,X
EOR #$FF
AND MSIGX
E1S050
STA MSIGX ;SET ENEMY1 X POINT MSB
LDA #01
STA SPRITA,X ;SET ENEMY1 MODE
STA SPRITB,X ;SET DEC TIME
LDA EN1WTF
STA SPRITC,X ;SET FIX TIME
LDA RANDOM
STX WK0
LSR WK0
CLC
ORA WK0
AND #$0F
STA SPRITD,X ;SET DIRECTION
LDA SPENA
ORA MASKS,X
STA SPENA ;SPRITE ENABLE
;
;----- CLEAR ENEMY 2
TYA
TAX ;X=ENEMEY2 INDEX
JSR BITCHR ;GET SCREEN ADDRESS (WK0,WK1)
LDA #00
TAY
STA (WK0),Y
INY
STA (WK0),Y
INY
STA (WK0),Y
LDY #40
STA (WK0),Y
INY
STA (WK0),Y
INY
STA (WK0),Y
LDY #80
STA (WK0),Y
INY
STA (WK0),Y
E1S900
RTS
;*--------------------------------------------------*
;* ENEMY3 SET *
;*--------------------------------------------------*
EN3SET
LDA EN3WTV ;SET TIME OK ?
BNE E3S900 ;NO EXIT
LDA EN3WTF ;GET ENEMY3 DISPLAY WAIT FIX TIME
STA EN3WTV ;SET IT DEC TIME
LDA RANDOM
AND #$02
BNE E3S900 ;EXIT
LDX #05
LDA SPRITA,X ;ENEMY1A LIVE ?
BPL E3S010 ;YES
INX
LDA SPRITA,X ;ENEMY1B LIVE ?
BMI E3S900 ;EXIT
E3S010
LDY #07
E3S020
LDA ENMY3A,Y
CMP #$FF ;ALLREDY USED ?
BEQ E3S030 ;NO
DEY
BPL E3S020
BMI E3S900 ;EXIT FULL
E3S030
LDA RANDOM
AND #01
STA ENMY3A,Y ;SET DISPLAY MODE
STX WK0 ;SAVE X-REG
TXA
ASL A
TAX
CLC
LDA SP0Y,X
ADC #08
AND #$F8
STA EN3YP,Y ;SET Y POINTER
CLC
LDA SP0X,X
ADC #08
AND #$F8
STA EN3XPL,Y ;SET X POINT L
LDX WK0 ;GET SPRITE NUMBER
LDA #00
STA EN3XPH,Y ;SET X POINT H
BCS E3S040
LDA MSIGX
AND MASKS,X
BEQ E3S900
E3S040
TYA
TAX
INC EN3XPH,X
E3S900
RTS
;*--------------------------------------------------*
;* SHIP MOVE *
;*--------------------------------------------------*
SHPMOV
LDA SPRITA ;GET SHIP MODE
BPL *+3 ;SHIP LIVE?
RTS ;NO
JSR READSW ;PLAYER'S SW READ
LDX THRUST ;THRUST?
BPL SHM030 ;NO
LDA KILLSP ;SHIP MOVE KILL TIME=0?
BEQ SHM010 ;YES
DEC KILLSP
BNE SHM020
SHM010
LDA ACSSEL ;ALREDY START?
BEQ SHM015 ;NO
LDA #$03 ;THRUST SOUND ON
JSR SOUND
LDX SPRITD ;GET NOW DIRECTION
LDY ROTATE ;GET NEW DIRECTION
CLC ;MAKE NEW X VECTOL
LDA WALKX,X
ADC WALKX,Y
CMP #$FE
BCS SHM011
CMP #$03
BCC SHM011
LDA WALKX,Y
SHM011
STA WK0 ;SAVE NEW X VECTOL
CLC ;MAKE NEW Y VECTOL
LDA WALKY,X
ADC WALKY,Y
CMP #$FE
BCS SHM012
CMP #$03
BCC SHM012
LDA WALKY,Y
SHM012
STA WK1 ;SAVE NEW Y VECTOL
LDX #$0F
SHM013
LDA WALKX,X
CMP WK0
BNE SHM014
LDA WALKY,X
CMP WK1
BEQ SHM016
SHM014
DEX
BPL SHM013
SHM015
LDX ROTATE
SHM016
STX SPRITD ;SET NEW DIRECTION
LDY #$01
STY SPRITC ;SET TOP SPEARD
STY ACSSEL ;ACSSEL ON
SHM020
LDA #$10 ;THRUST SELECT BIT ON
BNE SHM040
SHM030
LDA #$83 ;THRUST SOUND OFF
JSR SOUND
LDA #$00
SHM040
ORA ROTATE ;GET NOW SHIP DIRECTION
STA SPRITA ;SET SHIP MODE
JSR SHPDSP ;SHIP DISPLAY
LDY SPRITC
DEY ;TOP SPEARD?
BNE SHM060 ;NO
LDA CYCLE ;MOTION WAIT CHECK
AND #$03
BEQ SHM090
SHM060
LDA ACSSEL
BEQ SHM090
SHM070
LDX #00
JSR SPRMOV ;SHIP MOVE
LDA WK5 ;LIMIT ARIVE?
BMI SHM090 ;NO
LDY SPRITC
CPY #03 ;LOW SPEARD?
BEQ SHM090 ;YES
INC SPRITC ;SPEARD DOWN
SHM090
RTS
;*--------------------------------------------------*
;* READ SW, JMP USED DEVICE *
;*--------------------------------------------------*
READSW
LDA SCANF
BNE *+5
JMP RDKEY
JMP RDPAD
;*--------------------------------------------------*
;* SHIP DISPLAY *
;*--------------------------------------------------*
SHPPTN = $F500
SHPDSP
LDA SPRITA ;SHIP LIVE?
BMI SPD090 ;NO
AND #$1F
ASL A
ASL A
ASL A
STA WK2 ;SAVE *8
ASL A
STA WK0 ;STOR *16
LDA #>SHPPTN
ADC #00
STA WK1
CLC
LDA WK0
ADC WK2
STA WK0
LDA WK1
ADC #00
STA WK1
LDY #00
LDX #00
SPD010
LDA (WK0),Y ;PATTERN
STA $206,X ;IT SET TO RAM
INY
INX
LDA (WK0),Y
STA $206,X
INY
INX
INX
CPY #$18
BNE SPD010
SPD090
RTS
;*--------------------------------------------------*
;* SHIP'S MISSLE SET BY FIRE BUTTON *
;*--------------------------------------------------*
MSLPTN =$FF00
MSLSET
LDA SPRITA ;SHIP LIVE?
BMI MSL090 ;NO
LDA DFIRE ;FIRE OK?
BEQ MSL090 ;NO
LDX #04 ;MISSLE FULL?
MSL010
LDA SPRITA,X ;GET MODE
CMP #$FF ;DONE?
BEQ MSL020 ;YES
DEX
BNE MSL010
STX DFIRE ;CLEAR FIRE BIT
BEQ MSL090 ;FULL EXIT
;
;----- SET MISSLE DIRECTION
MSL020
LDA #00
STA DFIRE ;CLEAR FIRE BIT
STA SPRITA,X ;MODE=0 BIGEN MISSLE
LDA ROTATE ;GET DIRECTION
STA SPRITD,X ;GET IT
LDA #$02 ;MISSLE SOUND ON
JSR SOUND ;
;
;----- SET MISSLE ADDRESS POINT
LDA MSIGX
AND MASKS
BEQ MSL030
LDA MSIGX
ORA MASKS,X
STA MSIGX ;SET MISSLE X POINTER MSB
MSL030
TXA
ASL A
TAY ;Y=X*2
LDA SP0X
STA SP0X,Y ;SET MISSLE X POINTER
LDA SP0Y
STA SP0Y,Y ;SET MISSLE Y POINTER
;
;----- AFTER MODULE CALL BY ENEMY'S MISSLE ROUTINE
MSLBGN
;
;----- SET MISSLE PATTERN
LDA SPENA
ORA MASKS,X
STA SPENA ;SET SPRITE ENABLE BIT
LDA SPRITD,X
AND #$07
ASL A
ASL A
ASL A ;*8
TAX ;PATTERN INDEX
LDA SPRTBL,Y
STA WK0
LDA SPRTBL+1,Y
STA WK1
LDY #$15
MSL050
LDA MSLPTN,X
STA (WK0),Y
INX
INY
LDA MSLPTN,X
STA (WK0),Y
INX
INY
INY
CPY #$21
BNE MSL050
MSL090
RTS
SPRTBL .WORD $0200,$0240,$0280,$02C0
.WORD $0300,$0340,$0380,$03C0
.END

651
OMEGA/omega004

@ -0,0 +1,651 @@
.PAGE 'OMEGA004'
;*--------------------------------------------------*
;* SHIP'S MISSLE, MOVE, CHECK LIMIT AND COLLISION *
;* COLLISION CHECK SHIP TO ENEMY *
;*--------------------------------------------------*
MSLMOV
LDX #04
STX SPRIDX
MSL100
LDX SPRIDX
LDA SPRITA,X ;SPRITE EXIST?
BPL MSL110 ;YES
MSL104
DEC SPRIDX
BPL MSL100
JMP ENMMSL ;ENEMY'S MISSLE MODULE
MSL110
CPX #00 ;SHIP CHECK?
BEQ MSL130 ;YES
JSR SPRMOV ;SPRITE MOVE
LDA WK5 ;MISSLE ARIVE LIMIT?
BMI MSL130 ;NO
;
;----- MISSLE ARIVE LIMIT
MSL120
LDA #$FF
STA SPRITA,X ;OFF MISSLE MODE
EOR MASKS,X
AND SPENA
STA SPENA ;OFF SPRITE ENABLE BIT
LDA MASKS,X ;OFF X POINT MSB
EOR #$FF
AND MSIGX
STA MSIGX
JMP MSL300
;
;----- COLLISION CHECK SHIP-MISSLE TO ANOTHER
MSL130
LDA SPRITA ;SHIP LIVE?
BMI MSL104 ;NO, NOT COLLISION CHECK
LDX SPRIDX
TXA
ASL A
TAY ;Y=X*2
LDA #00
STA WK1
LDA MASKS,X
AND MSIGX ;GET X MSB
BEQ *+4
INC WK1 ;SAVE IT
LDA SP0X,Y ;GET X POINT
STA WK0 ;SAVE IT
LDA SP0Y,Y ;GET Y POINT
STA WK2 ;SAVE IT
LDA COLLSS ;GET SPRITE TO SPRITE
AND MASKS,X ;COLLISION?
BNE MSL140 ;YES
JMP MSL200 ;NO, GO TO SPRITE TO CHRACTER
;
;----- SPRITE TO SPRITE
MSL140
LDX #$07
MSL150
LDA SPRITA,X ;SPRITE EXIST?
BPL MSL170 ;YES
MSL160
DEX
CPX #$04
BNE MSL150
JMP MSL200 ;CHECK END SPRITE TO SPRITE
MSL170
JSR SPRSTS ;CHECK COLLISION POINT
LDA SPRITA,X
BPL MSL160
BMI MSL104 ;JMP
;*--------------------------------------------------*
;* SPRITE TO SPRITE COLLISION POINT CHECK *
;*--------------------------------------------------*
SPRSTS
TXA
PHA ;PUSH X
LDA COLLSS
AND MASKS,X ;SPRITE N COLLISION?
BNE *+5 ;YES
JMP STS090 ;NO
LDA SPRITA,X ;SPRITE N LIVE?
BMI STS090 ;NO
TXA
ASL A
TAY
LDA SP0Y,Y
STA WK5 ;WK5=SPNY
LDA SP0X,Y
STA WK3 ;WK3=SPNX L
LDA #00
STA WK4 ;WK4=SPNX H
LDA MSIGX
AND MASKS,X
BEQ *+4
INC WK4
LDA SPRITA,X
CMP #02 ;ENEMY0?
BCC STS010 ;NO
LDA #08 ;Y1+12 < Y2+4 TRUE NOT COLLISION
STA WK6
LDA #04 ;Y1+8 > Y2+12 TRUE NOT COLLISION
STA WK7
LDA #06 ;X1+10 < X2+4 TRUE NOT COLLISION
STA WK8
LDA #06+06 ;X1+6 > X2+12 TRUE NOT COLLISION
STA WK9
JSR CKCOLL ;CHECK 8X8 COLLISION
BCC STS090 ;NO COLLISION
LDA #$25 ;2500 POINT
BNE STS020 ;JMP
STS010
LDA #10 ;Y1+12 < Y2+2 TRUE NOT COLLISION
STA WK6
; ;X1+12 < X2+2 TRUE NOT COLLISION
STA WK8
LDA #11 ;Y1+2 > Y2+13 TRUE NOT COLLISION
STA WK7
LDA #11+10 ;X1+2 > X2+13 TRUE NOT COLLISION
STA WK9
JSR CKCOLL ;CHECK 16X16 COLLISION
BCC STS090 ;NO COLLISION
LDA #$15 ;1500 POINT
CPX #07
BEQ STS030 ;YES
STS020
JSR SCORUP ;SCORING
STS030
LDA #$FF
STA SPRITA,X ;KILL SPRITE N
EOR MASKS,X
AND SPENA
STA SPENA
LDX SPRIDX
LDA #$80
STA SPRITA,X ;BOMB START
STS090
PLA ;PULL X
TAX
RTS
;
;----- SPRITE TO CHARACTER ENEMY2
MSL200
LDX SPRIDX
LDA COLLSC ;GET SPRITE TO CHRACTER
AND MASKS,X ;COLLISION?
BNE MSL204 ;YES
JMP MSL104 ;THIS MISSLE NO COLLISION
MSL204
LDX #$0A
MSL210
LDA ENMY2A,X
CMP #$FF ;ENEMY2 LIVE?
BNE MSL230 ;YES
MSL220
DEX
BPL MSL210
JMP MSL300 ;NOT COLLISION ENEMY2, GO TO ENEMY3 CHECK
MSL230
LDA EN2XPL,X
STA WK3
LDA EN2XPH,X
STA WK4
LDA EN2YP,X
STA WK5
LDA #08 ;Y1+12 < Y2+2+2 TRUE NOT COLLISION
STA WK6
LDA #07 ;Y1+8 > Y2+13+2 TRUE NOT COLLISION
STA WK7
LDA #09 ;X1+10 < X2+2-1 TRUE NOT COLLISION
STA WK8
LDA #06+09 ;X1+6 > X2+13-1 TRUE NOT COLLISION
STA WK9
JSR CKCOLL ;CHECK 16X16 COLLISION
BCC MSL220 ;NO COLLISION
;
;----- COLLISION ENEMY2
LDA #$10 ;1000 POINT
JSR SCORUP ;SCORE UP
LDA #$FF
STA ENMY2A,X ;KILL ENEMY2
LDA SPRIDX
JSR BADSET ;BOMB ADDRESS SET
;
;----- ENEMY2 CLEAR ON SCREEN
JSR BITCHR ;GET SCREEN ADDRESS (WK0,WK1)
CLC
LDA WK0
STA WORK+$00
ADC #40
STA WORK+$06
LDA WK1
STA WORK+$01
ADC #00
STA WORK+$07
CLC
LDA WK0
ADC #80
STA WORK+$0C
LDA WK1
ADC #00
STA WORK+$0D
LDA #00
STA WORK+$02
STA WORK+$03
STA WORK+$04
STA WORK+$08
STA WORK+$09
STA WORK+$0A
STA WORK+$0E
STA WORK+$0F
STA WORK+$10
LDY #$FE
STY WORK+$05
STY WORK+$0B
INY
STY WORK+$11
LDX #<WORK
LDY #>WORK
JSR CHROUT
LDX #<GMFRAM
LDY #>GMFRAM
JSR CHROUT
MSL290
LDX SPRIDX
LDA #$80
STA SPRITA,X ;BOMB START SPRITE 0---4
JMP MSL104
;
;----- SPRITE TO CHARACTER ENEMY3
MSL300
LDX SPRIDX
LDA COLLSC ;GET SPRITE TO CHRACTER
AND MASKS,X ;COLLISION?
BNE MSL304 ;YES
JMP MSL104 ;THIS MISSLE NO COLLISION
MSL304
LDX #07
MSL310
LDA ENMY3A,X ;ENEMY3 LIVE?
CMP #$FF
BNE MSL330 ;YES
MSL320
DEX
BPL MSL310
JMP MSL104
MSL330
LDA EN3YP,X
STA WK5
LDA EN3XPL,X
STA WK3
LDA EN3XPH,X
STA WK4
LDA #06 ;Y1+12 < Y2+4+2 TRUE NOT COLLISION
STA WK6
LDA #12 ;Y1+2 > Y2+12+2 TRUE NOT COLLISION
STA WK7
LDA #09 ;X1+12 < X2+4-1 TRUE NOT COLLISION
STA WK8
LDA #09+09 ;X1+2 > X2+12-1 TRUE NOT COLLISION
STA WK9
JSR CKCOLL ;CHECK 8X8 COLLISION
BCC MSL320 ;NO COLLISION
;
;----- COLLISION ENEMY3
LDA #$02
STA WK0 ;200 POINT
LDA ENMY3A,X
BEQ *+4
ASL WK0
LDA WK0 ;400 POINT
JSR SCORUP ;SCORE UP
LDA #$FF
STA ENMY3A,X ;KILL ENEMY3
TXA
CLC
ADC #11
TAX
LDA SPRIDX
JSR BADSET ;BOMB ADDRESS SET
JSR BITCHR ;GET SCREEN ADDRESS (WK0.WK1)
LDA WK0
STA WORK+$00
LDA WK1
STA WORK+$01
LDY #00
STY WORK+$02
DEY
STY WORK+$03
LDX #<WORK
LDY #>WORK
JSR CHROUT ;CLEAR ENEMY3
MSL390
LDX SPRIDX
LDA #$80
STA SPRITA,X ;BOMB START SPRITE 0---4
JMP MSL104
;*--------------------------------------------------*
;* COLLISION CHECK *
;* INPUT: WK0 SOURCE X POINT L (X1) *
;* WK1 X POINT H *
;* WK2 Y POINT (Y1) *
;* WK3 DESTINATION X POINT L (X2) *
;* WK4 X POINT H *
;* WK5 Y POINT (Y2) *
;* WK6=J, J=N-M, (Y1)+M < (Y2)+N ? ,N<M *
;* WK7=K, K=P-Q, (Y1)+Q >=(Y2)+P ? ,P>Q *
;* WK8=R, R=S-T, (X1)+T < (X2)+S ? ,T<S *
;* WK9=Z, U=V-W, (X1)+W >=(X2)+V ? ,V>W *
;* Z=R+U *
;*--------------------------------------------------*
CKCOLL
;
;----- CHECK Y COLLISION
SEC ;WK5-WK6 >= WK2?
LDA WK5
SBC WK6
CMP WK2
BCS CKCL80 ;NONE COLLISION
CLC ;WK5+WK7 < WK2?
LDA WK5
ADC WK7
CMP WK2
BCC CKCL80 ;NONE COLLISION
;
;----- CHECK X COLLISION
SEC ;(WK3,WK4)-WK8 >= (WK0,WK1)?
LDA WK3
SBC WK8
STA WK3
LDA WK4
SBC #00
STA WK4
SEC
LDA WK3
SBC WK0
LDA WK4
SBC WK1
BCS CKCL80 ;NONE COLLISION
LDA WK3 ;(WK3,WK4)+WK9 < (WK0,WK1)?
ADC WK9
STA WK3
LDA WK4
ADC #00
STA WK4
SEC
LDA WK3
SBC WK0
LDA WK4
SBC WK1
BCC CKCL80 ;NONE COLLISION
RTS ;COLLISION EXIT
CKCL80
CLC
RTS ;NONE COLLISION EXIT
;*--------------------------------------------------*
;* SCORE UPDATE *
;*--------------------------------------------------*
SCORUP
STX WORK ;SAVE X-REG
CMP #$10
BCC SCR010
DEC NUMENM ;DEC. ENEMY NUMBER
BPL SCR010 ;NOT AT ALL ENEMY DONE
LDA #$40
STA TIMER2
LDA #$7F
STA TIMER3 ;SET NEW ROUND BIGEN WAIT TIME
LDA #$0F ;BACK MUSIC CHENG
STA SNDDAT
LDA #$06 ;ALL KILL SOUND ON
JSR SOUND
SCR010
CLC
SED
ADC SCORE+1
STA SCORE+1
LDA SCORE+2
ADC #$00
STA SCORE+2
CLD
JSR DSPSCR ;SCORE DISPLAY
LDA XTRA ;CHECK FOR EXTRA SHIP
BNE SCR090 ;ALREADY
LDA SCORE+2
CMP #$04
BCC SCR090
LDA #01
STA XTRA
INC NUMSHP
JSR DSPSHP
LDA #$01 ;BOUNUS SOUND
JSR SOUND
SCR090
LDX WORK
RTS
;*--------------------------------------------------*
;* BOMB ADDRESS RESET *
;*--------------------------------------------------*
BADSET
STA WK0 ;SAVE MISSLE SPRITE INDEX
ASL A
TAY
LDA EN2YP,X
STA SP0Y,Y ;SET BOMB Y POINT
LDA EN2XPL,X
STA SP0X,Y ;SET BOMB X POINT
LDY WK0
LDA EN2XPH,X
BEQ BAD010
LDA MASKS,Y
ORA MSIGX
BNE BAD020
BAD010
LDA MASKS,Y
EOR #$FF
AND MSIGX
BAD020
STA MSIGX ;SET BOMB X POINT MSB
RTS
;*--------------------------------------------------*
;* BOMB DISPLAY BY SPRITE *
;*--------------------------------------------------*
BMBSPR
LDX #07
BMB005
LDA SPRITA,X
BMI BMB020
BMB010
DEX
BPL BMB005
RTS
BMB020
CMP #$FF ;NONE USED ?
BEQ BMB010 ;YES
INC SPRITA,X
LDA SPRITA,X
CMP #$82
BEQ BMB060 ;BOMB0 DSP.
CMP #$90
BEQ BMB07A ;BOMB1 DSP.
CMP #$A0
BEQ BMB08A ;BOBN0 DSP.
CMP #$B0
BNE BMB030
CPX #00
BNE BMB040
BMB030
CMP #$C0
BEQ BMB07A ;BOMB1 DSP.
CMP #$D0
BEQ BMB08A ;BOMB0 DSP.
CMP #$F0
BNE BMB010
;
;----- BOMB OFF
BMB040
LDA #$FF
STA SPRITA,X ;KILL MODE
LDA MASKS,X
EOR #$FF
AND SPENA
STA SPENA ;SPRITE DISABLE
LDA STABLE,X
STA SV07F8,X
LDA MASKS,X
EOR #$FF
AND MSIGX
STA MSIGX ;OFF X MSB
CPX #00
BNE BMB050
DEC NUMSHP ;SHIP COUNT DOWN
LDA #$40
STA TIMER2 ;SET NEW ROUND WAIT TIME
LDA #$7F
STA TIMER3
LDA #BLACK
STA EXTCOL ;BORDER COLOR
STA BGCOL0 ;BACKGROUND COLOR 0
LDA KOLOR
STA SP0COL
STA SP1COL
STA SP2COL
JSR SPRCLR
LDA #$85 ;EXPLOD. SOUND OFF
JSR SOUND ;OFF
BMB050
JSR SPRCLR ;USED RAM AREA CLEAR
JMP BMB010
BMB07A JMP BMB070
BMB08A JMP BMB080
;
;----- BOMB0 DISPLAY
BMB060
LDY #$F8 ;$FE00
CPX #00
BEQ *+5
JMP BMB068
LDA #03
STA SPRITA+1
STA SPRITA+2
STA SPRITC+1
STA SPRITC+2
LDA #$00
STA SPRITD+1
LDA #$06
STA SPRITD+2
LDY #02
LDX #01
JSR SETEN0
LDY #03
LDX #02
JSR SETEN0
LDY #04
LDX #03
JSR SETEN0
LDA #BLACK
STA SP0COL
STA SP1COL
STA SP2COL
LDA SP0X
STA SP1X
STA SP2X
LDA MSIGX
AND #$01
BEQ BMB064
LDA #$0E
ORA MSIGX
STA MSIGX
BMB064
LDA SP0Y
STA SP1Y
STA SP2Y
LDA SPENA
ORA #$0E
STA SPENA
LDY #$FA
LDA #$83 ;THRUST SOUND OFF
JSR SOUND
LDX #$02
JSR WAIT
LDA #$05 ;EXPLOD. ON
JSR SOUND
BNE BMB069
BMB068
LDA #$04 ;ENEMY BOMB
JSR SOUND
BMB069
TYA
STA SV07F8,X ;SET SPRITE MAP
JMP BMB010
;
;----- BOMB1 DISPLAY
BMB070
LDY #$F9 ;$FE40
CPX #00
BNE BMB074
LDA #ORANGE
STA EXTCOL ;
STA BGCOL0 ;
INY
INY
BMB074
TYA
STA SV07F8,X
JMP BMB010
BMB080
LDY #$F8 ;$FE00
CPX #00
BNE BMB084
LDA #RED
STA EXTCOL ;
STA BGCOL0 ;
STA TIMER3
INY
INY
BMB084
TYA
STA SV07F8,X ;SET SPRITE MAP
JMP BMB010
.END

146
OMEGA/omega005

@ -0,0 +1,146 @@
.PAGE 'OMEGA005'
;*--------------------------------------------------*
;* ENEMY'S MISSLE SET & MOVE *
;*--------------------------------------------------*
ENMMSL
LDA SPRITA+7 ;GET MISSLE MODE
BMI ENS000 ;LIVE?
;
;----- MISSLE MOVE
ENS200
LDX #07
JSR SPRMOV
LDA WK5 ;MISSLE ARIVE LIMIT?
BMI ENS900 ;NO
LDA #$FF
STA SPRITA,X
EOR MASKS,X
AND SPENA
STA SPENA
LDA MASKS,X
EOR #$FF
AND MSIGX
STA MSIGX
ENS900
RTS
;
;----- SET NEW MISSLE
ENS000
LDA TIMER1
AND #$20
BEQ ENS900
LDX #05
LDA SPRITA,X ;ENEMY1A LIVE?
BPL ENS010 ;YES
INX
LDA SPRITA,X ;ENEMY1B LIVE?
BMI ENS900 ;NO
ENS010
LDY #00
STY SPRITA+7 ;MODE BEGIN
INY
STY SPRITB+7 ;
STY SPRITC+7 ;SPEARD=1
LDA MSIGX
AND MASKS,X ;ENEMY1 X MSB ON?
BEQ ENS020 ;NO
LDA MSIGX
ORA MASKS+7
STA MSIGX ;SET MISSLE X MSB
ENS020
TXA
ASL A
TAY
LDA SP0X,Y
STA SP7X ;SET MISSLE X POINT
LDA SP0Y,Y
STA SP7Y ;SET MISSLE Y POINT
;
;----- MAKE MISSLE DIRECTION
LDA #00
STA WK1 ;MSB WORK
STA WK4 ;X NEGATIV FLAG
STA WK5 ;Y NEGATIV FLAG
LDA MSIGX
AND MASKS,X
BEQ ENS030
INC WK1 ;MSB ON
ENS030
SEC
LDA SP0X
SBC SP0X,Y
STA WK0
LDA MSIGX
AND #01
SBC WK1
BCS ENS040
INC WK4 ;X NEGATIV FLAG ON
LDA #$FF
EOR WK0
STA WK0
LDA #$FF
EOR WK1
ENS040
STA WK1 ;WK1=X DISTANCE
SEC
LDA SP0Y
SBC SP0Y,Y
BCS ENS050
INC WK5 ;Y NEGATIV FLAG ON
LDA #$FF
EOR WK2
ENS050
STA WK2 ;WK2=Y DISTANCE
LSR WK1
ROR WK0 ;X/2
LDY #00
ENS060
CLC
LDA WK2
SBC WK0
STA WK2
BCC ENS070
INY
CPY #06
BNE ENS060
ENS070
LDA ENDRTB,Y
STA WK6 ;DIRECTION NUMBER
LDY WK4 ;X NEGATIV?
BEQ ENS080 ;NO
CLC
LDA #00
SBC WK6
AND #$0F
STA WK6
ENS080
LDY WK5 ;Y NEGATIVE?
BEQ ENS090 ;NO
CLC
LDA #08
SBC WK6
AND #$0F
ENS090
STA SPRITD+7
LDX #07
LDY #$0E
JMP MSLBGN
ENDRTB .BYTE 04,05,06,06,07,07,08
.END

219
OMEGA/omega006

@ -0,0 +1,219 @@
.PAGE 'OMEGA006'
*=$FDA0
;*---------------------------------------------------------*
;* SOUND ON-OFF *
;*---------------------------------------------------------*
SOUND
;----- BOUNUS
SND100
CMP #$01
BNE SND200
LDA #$08
STA SNDDAT
RTS
;
;----- MISSLE
SND200
CMP #$02
BNE SND300
LDA #$0F
STA LASER
LDA #$F2
STA SUREL2
LDA #$21
STA VCREG2
RTS
;
;----- THRUST
SND300
CMP #$03
BNE SND400
LDA #$81
STA SUREL3
STA VCREG3
INC THRSND
STA FREHI3
RTS
;
;----- ENEMY BOMB
SND400
CMP #$04
BNE SND500
LDA #$07
STA BOMBFL
LDA #$21
STA VCREG1
RTS
;
;----- EXPLOD ON
SND500
CMP #$05
BNE SND60A
LDA #$0F
STA EXPLOD
LDA #$FD
STA SUREL3
LDA #$81
STA VCREG3
LDA #$20
STA VCREG1
RTS
SND60A JMP SND600
.PAGE
*=$FE00
;
;----- SMALL EXPLOSION
.BYTE %00000000,%00000000,%00000000 ; IN
.BYTE %00000000,%00000000,%00000000 ; 1
.BYTE %00000000,%00000000,%00000000 ; 2
.BYTE %00000001,%00000000,%00000000 ; 3
.BYTE %00001001,%00100000,%00000000 ; 4
.BYTE %00000101,%01000000,%00000000 ; 5
.BYTE %00000000,%00000000,%00000000 ; 6
.BYTE %00011100,%01110000,%00000000 ; 7
.BYTE %00000000,%00000000,%00000000 ; 8
.BYTE %00000101,%01000000,%00000000 ; 9
.BYTE %00001001,%00100000,%00000000 ;10
.BYTE %00000001,%00000000,%00000000 ;11
.BYTE %00000000,%00000000,%00000000 ;12
.BYTE %00000000,%00000000,%00000000 ;13
.BYTE %00000000,%00000000,%00000000 ;14
.BYTE %00000000,%00000000,%00000000 ;15
.BYTE %00000000,%00000000,%00000000 ;16
.BYTE %00000000,%00000000,%00000000 ;17
.BYTE %00000000,%00000000,%00000000 ;18
.BYTE %00000000,%00000000,%00000000 ;19
.BYTE %00000000,%00000000,%00000000 ;20
.BYTE %00000000
.BYTE %00001001,%00100000,%00000000 ;OUT
.BYTE %01001001,%00100100,%00000000 ; 1
.BYTE %00100101,%01001000,%00000000 ; 2
.BYTE %00010000,%00010000,%00000000 ; 3
.BYTE %11000000,%00000110,%00000000 ; 4
.BYTE %00100000,%00001000,%00000000 ; 5
.BYTE %00000000,%00000000,%00000000 ; 6
.BYTE %11100000,%00001110,%00000000 ; 7
.BYTE %00000000,%00000000,%00000000 ; 8
.BYTE %00100000,%00001000,%00000000 ; 9
.BYTE %11000000,%00000110,%00000000 ;10
.BYTE %00010000,%00010000,%00000000 ;11
.BYTE %00100101,%01001000,%00000000 ;12
.BYTE %01001001,%00100100,%00000000 ;13
.BYTE %00001001,%00100000,%00000000 ;14
.BYTE %00000000,%00000000,%00000000 ;15
.BYTE %00000000,%00000000,%00000000 ;16
.BYTE %00000000,%00000000,%00000000 ;17
.BYTE %00000000,%00000000,%00000000 ;18
.BYTE %00000000,%00000000,%00000000 ;19
.BYTE %00000000,%00000000,%00000000 ;20
.BYTE %00000000
;----- BIG EXPLOSION
.BYTE %00000000,%00000000,%00000000 ; IN
.BYTE %00000000,%00000000,%00000000 ; 1
.BYTE %00000000,%00000000,%00000000 ; 2
.BYTE %00000000,%00010000,%00000000 ; 3
.BYTE %00000000,%10010010,%00000000 ; 4
.BYTE %00000010,%01010100,%10000000 ; 5
.BYTE %00000001,%01010101,%00000000 ; 6
.BYTE %00000000,%10010010,%00000000 ; 7
.BYTE %00000110,%01010100,%11000000 ; 8
.BYTE %00000000,%00000000,%00000000 ; 9
.BYTE %00001111,%11000111,%11100000 ;10
.BYTE %00000000,%00000000,%00000000 ;11
.BYTE %00000110,%01010100,%11000000 ;12
.BYTE %00000000,%10010010,%00000000 ;13
.BYTE %00000001,%01010101,%00000000 ;14
.BYTE %00000000,%10010010,%00000000 ;15
.BYTE %00000000,%00010000,%00000000 ;16
.BYTE %00000000,%00000000,%00000000 ;17
.BYTE %00000000,%00000000,%00000000 ;18
.BYTE %00000000,%00000000,%00000000 ;19
.BYTE %00000000,%00000000,%00000000 ;20
.BYTE %00000000
.BYTE %00000010,%00010000,%10000000 ;OUT
.BYTE %00100001,%00010001,%00001000 ; 1
.BYTE %00010001,%00010001,%00010000 ; 2
.BYTE %00001000,%10010010,%00100000 ; 3
.BYTE %00000100,%01000100,%01000000 ; 4
.BYTE %00000010,%00000000,%10000000 ; 5
.BYTE %01100000,%00000000,%00001100 ; 6
.BYTE %00011000,%00000000,%00110000 ; 7
.BYTE %00000000,%00000000,%00000000 ; 8
.BYTE %00000000,%00000000,%00000000 ; 9
.BYTE %11110000,%00000000,%00011110 ;10
.BYTE %00000000,%00000000,%00000000 ;11
.BYTE %00000000,%00000000,%00000000 ;12
.BYTE %00011000,%00000000,%00110000 ;13
.BYTE %01100000,%00000000,%00001100 ;14
.BYTE %00000010,%00000000,%10000000 ;15
.BYTE %00000100,%01000100,%01000000 ;16
.BYTE %00001000,%10010010,%00100000 ;17
.BYTE %00010001,%00010001,%00010000 ;18
.BYTE %00100001,%00010001,%00001000 ;19
.BYTE %00000010,%00010000,%10000000 ;20
.BYTE %00000000
.PAGE
*=$FF00
;*------------------------------------------------------*
;* MISSILE PATTERN *
;*------------------------------------------------------*
.BYTE %00000001,%00000000 ; (0)
.BYTE %00000001,%00000000
.BYTE %00000001,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%10000000 ; (1)
.BYTE %00000001,%00000000
.BYTE %00000010,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%10000000 ; (2)
.BYTE %00000001,%00000000
.BYTE %00000010,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%10000000 ; (3)
.BYTE %00000001,%00000000
.BYTE %00000010,%00000000
.BYTE %00000000,%00000000
.BYTE %00000001,%11100000 ; (4)
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000001,%00000000 ; (5)
.BYTE %00000000,%10000000
.BYTE %00000000,%01000000
.BYTE %00000000,%00000000
.BYTE %00000001,%00000000 ; (6)
.BYTE %00000000,%10000000
.BYTE %00000000,%01000000
.BYTE %00000000,%00000000
.BYTE %00000001,%00000000 ; (7)
.BYTE %00000000,%10000000
.BYTE %00000000,%01000000
.BYTE %00000000,%00000000
.END

139
OMEGA/omega007

@ -0,0 +1,139 @@
.PAGE 'OMEGA007'
*=$FF40
;*--------------------------------------------------*
;* SOUND CONTROL SUBROUTIN CALL BY ONE CYCLE *
;*--------------------------------------------------*
SOUNDM
;
;----- MISSLE
SNM200
LDA LASER
BEQ SNM400
ASL A
ASL A
ASL A
STA FREHI2
DEC LASER
BNE SNM400
LDA #$20
STA VCREG2
;
;----- ENEMY BOMB
SNM400
LDA BOMBFL
BEQ SNM500
ASL A
ASL A
ASL A
STA FREHI1
DEC BOMBFL
BNE SNM500
LDA #$20
STA VCREG1
;
;----- EXPLOD
SNM500
LDA EXPLOD
BEQ SNM600
LDA SP1Y
STA FREHI3
;
;----- BACK
SNM600
LDA EXPLOD
ORA BOMBFL
; ORA EMARGE
BNE SNM700
LDA SPRITA+5
ORA SPRITA+6
CMP #$02
BCC *+4
DEC SNDTIM
DEC SNDTIM
BPL SNM700
LDA #$21
STA VCREG1
LDY SNDDAT
INC SNDDAT
INC SNDDAT
INC SNDDAT
LDA SNDTB1+2,Y
STA SNDTIM
LDA SNDTB1+1,Y
STA FRELO1
LDA SNDTB1,Y
STA FREHI1
BNE SNM700
STA SNDDAT
LDA #$20
STA VCREG1
;
;----- EMARGENCY
SNM700
; LDA EMARGE
; BEQ SNM800
; LDA TIMER1
; AND #$7F
; STA FREHI1
; BNE SNM800
; DEC EMARGE
; LDA #$21
; STA VCREG1
SNM800
RTS
;
;----- ENEMY ALL KILL
SND600
;
;----- THRUST OFF
SNF300
CMP #$83
BNE SNF500
LDA #$00
STA THRSND
LDA EXPLOD
BNE SNF399
LDA #$80
STA VCREG3
SNF399
RTS
;
;----- EXPLOD OFF
SNF500
CMP #$85
BNE SNF599
LDA #$80
STA VCREG3
LDA #$20
STA VCREG1
STA VCREG2
LDA #$00
STA EXPLOD
STA BOMBFL
STA LASER
STA SNDDAT
SNF599
RTS
;
;----- SPRITE MOTION DISTANCE TABLE
WALKY
.BYTE $FE,$FE,$FE,$FF,$00,$01,$02,$02
.BYTE $02,$02,$02,$01,$00,$FF,$FE,$FE
WALKX
.BYTE $00,$01,$02,$02,$02,$02,$02,$01
.BYTE $00,$FF,$FE,$FE,$FE,$FE,$FE,$FF
.END

1208
OMEGA/omegachr

File diff suppressed because it is too large Load Diff

7
OMEGA/omegaend

@ -0,0 +1,7 @@
.PAGE 'OMEGAEND'
*=$FFFA
.WORD $E000,$E000,$E000
.END

79
OMEGA/omegaram

@ -0,0 +1,79 @@
.PAGE 'OMEGARAM'
*=$02
BEGIN *=*+0
;
;----- WORKING REGISTER IN CLOSED ROUTINE
WK0 *=*+1
WK1 *=*+1
WK2 *=*+1
WK3 *=*+1
WK4 *=*+1
WK5 *=*+1
WK6 *=*+1
WK7 *=*+1
WK8 *=*+1
WK9 *=*+1
KOLOR *=*+2 ;COLOR OF SHIP & CHRACTER (DEFAULT WHITE)
SCANF *=*+1 ;INPUT SCAN FLAG (0=KEY 1=PADDLE 2=JOYSTIK)
COLLSS *=*+1 ;COLLISION SPRITE TO SPRITE
COLLSC *=*+1 ;COLLISION SPRITE TO CHARACTER
TIMER1 *=*+1 ;INC. TIMER AT 16MS(ONE SYNC)
TIMER2 *=*+1 ;INC. TIMER AT 16MS
TIMER3 *=*+1 ;INC. TIMER AT 256 X 16MS
CYCLE *=*+1 ;INC. CYCLE 0 TO 7 AT 16MS
CYCLEP *=*+1
WATCHR *=*+1 ;CHRACTER DSPLAY WAIT FLAG
LSCORE *=*+3 ;LAST HIGH SCORE
SCORE *=*+3 ;PLAYER'S SCORE
FIRE *=*+1
DFIRE *=*+1
ROTATE *=*+1
THRUST *=*+1
FTIME *=*+1
ACSSEL *=*+1 ;SHIP ACSSEL 0 TO 0B
KILLSP *=*+1 ;SHIP KILL SW TIMER
NUMSHP *=*+1 ;PLAYER'S SHIP NUMBER
NUMENM *=*+1 ;ENEMIES NUMBER
XTRA *=*+1 ;BOUNUS CHECK FLAG
ROUND *=*+1 ;ROUND COUNTER
LINTIM *=*+8 ;FLAME ON-OFF TIME
ENROTE *=*+1 ;ENEMIES ROTATION
EN0WTF *=*+1 ;ENEMY0 MAKE INTERVAL TIME FIX
EN0WTV *=*+1 ;ENEMY0 MAKE INTERVAL TIME VALIABLE
EN1WTF *=*+1 ;ENEMY1 MOVE WAIT TIME FIX
EN1WTV *=*+1 ;ENEMY1 MOVE WAIT TIME VALIABLE
EN2WTF *=*+1 ;ENEMY2 MOVE WAIT TIME FIX
EN2WTV *=*+1 ;ENEMY2 MOVE WAIT TIME VALIABLE
EN3WTF *=*+1 ;ENEMY3 MAKE INTERVAL TIME FIX
EN3WTV *=*+1 ;ENEMY3 MAKE INTERVAL TIME VALIABLE
ENMY2A *=*+11 ;ENEMY2 MOVE TABLE
ENMY3A *=*+8 ;ENEMY3 MOVE TABLE
EN2YP *=*+11 ;ENEMY2 Y POINTER
EN3YP *=*+8 ;ENEMY3 Y POINTER
EN2XPL *=*+11 ;ENEMYE2 X(LOW) POINTER
EN3XPL *=*+8 ;ENEMY3 X(LOW) POINTER
EN2XPH *=*+11 ;ENEMY2 X(HIGH) POINTER
EN3XPH *=*+8 ;ENEMY3 X(HIGH) POINTER
EN2IDX *=*+1 ;ENEMIES 2 DSP. INDEX
SPRIDX *=*+1 ;SPRITE INDEX
SPRITA *=*+8 ;SPRITE MODE (DONE=-1)
SPRITB *=*+8 ;SPRITE MOVE WAIT TIMER
SPRITC *=*+8 ;SPRITE MOVE WAIT FIXED TIMER
SPRITD *=*+8 ;SPRITE DIRECTION
SNDDAT *=*+1 ;
SNDTIM *=*+1 ;
LASER *=*+1 ;
BOMBFL *=*+1 ;
THRSND *=*+1 ;THRUST SOUND FRQ.
EXPLOD *=*+1 ;
EMARGE *=*+1 ;
KEYSAV *=*+1 ;KEY SAVE
SV07F8 *=*+8 ;USED DBG.
WORK *=*+20 ;WORKING AREA
.END

759
OMEGA/omegatbl

@ -0,0 +1,759 @@
.PAGE 'OMEGATBL'
VICTBL .BYTE $00,$00,$00,$00,$00,$00,$00,$00 ;VIC 00-07
.BYTE $00,$00,$00,$00,$00,$00,$00,$00 ;VIC 08-0F
.BYTE $00,$1B,$00,$00,$00,$00,$0B,$00 ;VIC 10-17
.BYTE $1E,$FF,$00,$00,$00,$00,$00,$00 ;VIC 18-1F
.BYTE $01,$01,$00,$00,$00,$00,$00,$01 ;VIC 20-27
.BYTE $01,$01,$01,$01,$01,$01,$01 ;VIC 28-2E
SIDTBL .BYTE $00,$20,$00,$00,$20,$00,$F9 ;SID V1
.BYTE $FF,$00,$00,$00,$20,$00,$FD ;SID V2
.BYTE $FF,$FF,$00,$00,$80,$00,$F0 ;SID V3
.BYTE $FF,$FF,$07,$1F ;SID CTRL
TITLE
.WORD SCREEN+200+6
.BYTE $2C,$2D,$00,$15,$0F,$23,$1D,$00,$00 ;F1 KEYS
.BYTE $16,$27,$10,$13,$1C,$0F,$00,$00 ;A-FIRE
.BYTE $28,$27,$16,$0B,$1F,$18,$0D,$12,$FE ;L-LAUNCH
.WORD SCREEN+240+15
.BYTE $0B,$27,$16,$0F,$10,$1E,$00,$00 ;A-LEFT
.BYTE $0E,$27,$1C,$13,$11,$12,$1E,$FE ;D-RIGHT
.WORD SCREEN+360+6
.BYTE $2C,$2E,$00,$14,$19,$23,$1D,$1E,$13 ;F3 JOYSTICK
.BYTE $0D,$15,$FE
.WORD SCREEN+480+6
.BYTE $2C,$2F,$00,$1A,$0B,$0E,$0E,$16,$0F ;F5 PADDLE
.BYTE $FE
.WORD SCREEN+600+6
.BYTE $2C,$30,$00,$1D,$12,$13,$1A ;F7 SHIP COLOR
.BYTE $00,$0D,$19,$16,$19,$1C,$FE
.WORD SCREEN+720+6
.BYTE $2C,$31,$00,$1D,$0D,$1C,$0F,$0F,$18 ;F8 SCREEN COLOR
.BYTE $00,$0D,$19,$16,$19,$1C,$FE
.WORD SCREEN+840+5 ;1982 BY COMMODORE LTD.
.BYTE $02,$0A,$09,$03,$00,$0C,$23,$00,$0D,$19,$17,$17
.BYTE $19,$0E,$19,$1C,$0F,$00,$16,$1E,$0E,$29,$FE
.WORD SCREEN+920+5 ;1981 BY BALLY-MIDWAY. V03
.BYTE $02,$0A,$09,$02,$00,$0C,$23,$00
.BYTE $0C,$0B,$16,$16,$23,$27,$17,$13,$0E,$21,$0B,$23
.BYTE $29,$00,$00,$20,$01,$04,$FF
GMSCRN
.WORD SCREEN+0+0
.BYTE $32,$FE
.WORD SCREEN+0+19
.BYTE $33,$FE
.WORD SCREEN+0+39
.BYTE $34,$FE
.WORD SCREEN+400+15
.BYTE $1D,$0D,$19,$1C
.BYTE $0F,$FE
.WORD SCREEN+480+0
.BYTE $39,$FE
.WORD SCREEN+480+12
.BYTE $12,$13,$27,$1D,$0D,$19,$1C
.BYTE $0F,$FE
.WORD SCREEN+480+39
.BYTE $35,$FE
.WORD SCREEN+560+12
.BYTE $1D,$12,$13,$1A,$FE
.WORD SCREEN+960+0
.BYTE $38,$FE
.WORD SCREEN+960+19
.BYTE $37,$FE
.WORD SCREEN+960+39
.BYTE $36,$FE
GMFRAM
.WORD SCREEN+360+11
.BYTE $41,$3C,$3C,$3C,$3C,$3C,$3C,$3C
.BYTE $3C,$3C,$3C,$3C,$3C,$3C,$3C,$3C
.BYTE $40,$FE
.WORD SCREEN+400+11
.BYTE $3B,$FE
.WORD SCREEN+400+27
.BYTE $3A,$FE
.WORD SCREEN+440+11
.BYTE $3B,$FE
.WORD SCREEN+440+27
.BYTE $3A,$FE
.WORD SCREEN+480+11
.BYTE $3B,$FE
.WORD SCREEN+480+27
.BYTE $3A,$FE
.WORD SCREEN+520+11
.BYTE $3B,$FE
.WORD SCREEN+520+27
.BYTE $3A,$FE
.WORD SCREEN+560+11
.BYTE $3B,$FE
.WORD SCREEN+560+27
.BYTE $3A,$FE
.WORD SCREEN+600+11
.BYTE $3F,$3D,$3D,$3D,$3D,$3D,$3D,$3D
.BYTE $3D,$3D,$3D,$3D,$3D,$3D,$3D,$3D
.BYTE $3E
.BYTE $FF
OVERMS
.WORD SCREEN+280+11
.BYTE $11,$00,$0B,$00,$17,$00,$0F,$00
.BYTE $00,$00,$19,$00,$20,$00,$0F,$00
.BYTE $1C,$FF
ENMCNT .BYTE 07-1,09-1,11-1,13-1 ;ROUND ENEMIES COUNT
EN0TM0 .BYTE 30,20,15,10 ;ENEMY0 BIGEN TIME
EN0TIM .BYTE 16,12,10,07 ;ENEMY0 RESET INTERVAL TIME
EN1TIM .BYTE 09,06,04,03 ;MOVE WAIT ENEMY1 (N*16MS)
EN2TIM .BYTE 02,02,01,01 ;MOVE WAIT ENEMY2 (N*7*16MS)
EN3TIM .BYTE 05,04,03,02 ;ENEMY3 DISPLAY INTERVAL TIME (SECOND)
;
;----- LINE DISPLAY TABLE
ONTB
.WORD ONTB0,ONTB1,ONTB2,ONTB3
.WORD ONTB5,ONTB4,ONTB7,ONTB6
HOFTB
.WORD HOFTB0,HOFTB1,HOFTB2,HOFTB3
.WORD HOFTB5,HOFTB4,HOFTB7,HOFTB6
OFFTB
.WORD OFFTB0,OFFTB1,OFFTB2,OFFTB3
.WORD OFFTB5,OFFTB4,OFFTB7,OFFTB6
ONTB0
.WORD SCREEN+1
.BYTE $3D,$3D,$3D,$3D,$3D,$3D,$3D,$3D
.BYTE $3D,$3D,$3D,$3D,$3D,$3D,$3D,$3D
.BYTE $3D,$3D,$FF
ONTB1
.WORD SCREEN+20
.BYTE $3D,$3D,$3D,$3D,$3D,$3D,$3D,$3D
.BYTE $3D,$3D,$3D,$3D,$3D,$3D,$3D,$3D
.BYTE $3D,$3D,$3D,$FF
ONTB2
.WORD SCREEN+40+39
.BYTE $3B,$FD,$3B,$FD,$3B,$FD,$3B,$FD
.BYTE $3B,$FD,$3B,$FD,$3B,$FD,$3B,$FD
.BYTE $3B,$FD,$3B,$FD,$3B,$FF
ONTB3
.WORD SCREEN+520+39
.BYTE $3B,$FD,$3B,$FD,$3B,$FD,$3B,$FD
.BYTE $3B,$FD,$3B,$FD,$3B,$FD,$3B,$FD
.BYTE $3B,$FD,$3B,$FD,$3B,$FF
ONTB4
.WORD SCREEN+960+20
.BYTE $3C,$3C,$3C,$3C,$3C,$3C,$3C,$3C
.BYTE $3C,$3C,$3C,$3C,$3C,$3C,$3C,$3C
.BYTE $3C,$3C,$3C,$FF
ONTB5
.WORD SCREEN+960+1
.BYTE $3C,$3C,$3C,$3C,$3C,$3C,$3C,$3C
.BYTE $3C,$3C,$3C,$3C,$3C,$3C,$3C,$3C
.BYTE $3C,$3C,$FF
ONTB6
.WORD SCREEN+520+0
.BYTE $3A,$FD,$3A,$FD,$3A,$FD,$3A,$FD
.BYTE $3A,$FD,$3A,$FD,$3A,$FD,$3A,$FD
.BYTE $3A,$FD,$3A,$FD,$3A,$FF
ONTB7
.WORD SCREEN+40
.BYTE $3A,$FD,$3A,$FD,$3A,$FD,$3A,$FD
.BYTE $3A,$FD,$3A,$FD,$3A,$FD,$3A,$FD
.BYTE $3A,$FD,$3A,$FD,$3A,$FF
HOFTB0
.WORD SCREEN+7
.BYTE $00,$00,$00,$00,$00,$00,$00,$00
.BYTE $FF
HOFTB1
.WORD SCREEN+25
.BYTE $00,$00,$00,$00,$00,$00,$00,$00
.BYTE $FF
HOFTB2
.WORD SCREEN+160+39
.BYTE $00,$FD,$00,$FD,$00,$FD,$00,$FD
.BYTE $00,$FF
HOFTB3
.WORD SCREEN+640+39
.BYTE $00,$FD,$00,$FD,$00,$FD,$00,$FD
.BYTE $00,$FF
HOFTB4
.WORD SCREEN+960+25
.BYTE $00,$00,$00,$00,$00,$00,$00,$00
.BYTE $FF
HOFTB5
.WORD SCREEN+960+7
.BYTE $00,$00,$00,$00,$00,$00,$00,$00
.BYTE $FF
HOFTB6
.WORD SCREEN+640
.BYTE $00,$FD,$00,$FD,$00,$FD,$00,$FD
.BYTE $00,$FF
HOFTB7
.WORD SCREEN+160
.BYTE $00,$FD,$00,$FD,$00,$FD,$00,$FD
.BYTE $00,$FF
OFFTB0
.WORD SCREEN+1
.BYTE $00,$00,$00,$00,$00,$00,$00,$00
.BYTE $00,$00,$00,$00,$00,$00,$00,$00
.BYTE $00,$00,$FF
OFFTB1
.WORD SCREEN+20
.BYTE $00,$00,$00,$00,$00,$00,$00,$00
.BYTE $00,$00,$00,$00,$00,$00,$00,$00
.BYTE $00,$00,$00,$FF
OFFTB2
.WORD SCREEN+40+39
.BYTE $00,$FD,$00,$FD,$00,$FD,$00,$FD
.BYTE $00,$FD,$00,$FD,$00,$FD,$00,$FD
.BYTE $00,$FD,$00,$FD,$00,$FF
OFFTB3
.WORD SCREEN+520+39
.BYTE $00,$FD,$00,$FD,$00,$FD,$00,$FD
.BYTE $00,$FD,$00,$FD,$00,$FD,$00,$FD
.BYTE $00,$FD,$00,$FD,$00,$FF
OFFTB4
.WORD SCREEN+960+20
.BYTE $00,$00,$00,$00,$00,$00,$00,$00
.BYTE $00,$00,$00,$00,$00,$00,$00,$00
.BYTE $00,$00,$00,$FF
OFFTB5
.WORD SCREEN+960+1
.BYTE $00,$00,$00,$00,$00,$00,$00,$00
.BYTE $00,$00,$00,$00,$00,$00,$00,$00
.BYTE $00,$00,$FF
OFFTB6
.WORD SCREEN+520
.BYTE $00,$FD,$00,$FD,$00,$FD,$00,$FD
.BYTE $00,$FD,$00,$FD,$00,$FD,$00,$FD
.BYTE $00,$FD,$00,$FD,$00,$FF
OFFTB7
.WORD SCREEN+40
.BYTE $00,$FD,$00,$FD,$00,$FD,$00,$FD
.BYTE $00,$FD,$00,$FD,$00,$FD,$00,$FD
.BYTE $00,$FD,$00,$FD,$00,$FF
EN2TB
.WORD EN2TB0,EN2TB1,EN2TB2,EN2TB3
EN2TB0 ;ENYMISE 2 RIGHT
.BYTE 13,15,19,17,12
.BYTE 10,19,9,14,5,18
EN2TB1 ;ENYMISE 2 LEFT
.BYTE $80+14,$80+10,$80+12,$80+16
.BYTE $80+19,$80+13,$80+10,$80+18,$80+07,$80+18,$80+05
EN2TB2 ;ENEMISE 2 (X) SPAN
.BYTE 27,25,31,33,31
.BYTE 23,27,27,21,23,23
EN2TB3 ;ENYMISE 2 (Y) SPAN
.BYTE 15,13,19,21,19
.BYTE 11,15,15,09,11,11
EN2BGN
.BYTE 200,192,216,224,216
.BYTE 184,200,200,176,184,184
.BYTE 176,152,144,168,200
.BYTE 184,128,208,144,224,120
.BYTE 000,000,000,000,000
.BYTE 000,000,000,000,000,000
;
;----- SPRITE MASK TABLE
MASKS
.BYTE %00000001
.BYTE %00000010
.BYTE %00000100
.BYTE %00001000
.BYTE %00010000
.BYTE %00100000
.BYTE %01000000
.BYTE %10000000
;
;----- SPRITE MOTION DISTANCE TABLE
;----------- BACK GRAND MUSIC TABLE ------------
SNDTB1
.BYTE $07,$EF,$15,$07,$7D,$15,$06,$4C
.BYTE $15,$07,$7D,$15,$00,$00,$00
;
;----------- ENEMY ALL CLARE MUSIC TABLE -------
SNDTB2
.BYTE $15,$2E,$10,$13,$FD,$10,$15,$2E,$10
.BYTE $16,$70,$13,$19,$30,$1E,$10,$CF,$1E
.BYTE $15,$2E,$10,$13,$FD,$10,$15,$2E,$10
.BYTE $16,$70,$13,$19,$30,$1E,$10,$CF,$1E
.BYTE $15,$2E,$10,$13,$FD,$10,$15,$2E,$10
.BYTE $16,$70,$13,$19,$30,$1E,$10,$CF,$1E
.BYTE $15,$2E,$10,$16,$70,$10,$15,$2E,$10
.BYTE $16,$70,$10,$12,$DE,$30,$00
.PAGE
*=$F500
;*======================================================*
;* *
;* OMEGA0P PATTERN (8X8) *
;* *
;*======================================================*
SHPDAT
;*------------------------------------------------------*
;* PLAYER CRAFTS *
;*------------------------------------------------------*
.BYTE %00000000,%00000000 ;0
.BYTE %00000001,%00000000
.BYTE %00000001,%00000000
.BYTE %00000010,%10000000
.BYTE %00000010,%10000000
.BYTE %00000100,%01000000
.BYTE %00000100,%01000000
.BYTE %00001000,%00100000
.BYTE %00001111,%11100000
.BYTE %00010000,%00010000
.BYTE %00010000,%00010000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000 ;1
.BYTE %00000000,%01000000
.BYTE %00000000,%11000000
.BYTE %00000001,%01000000
.BYTE %00000010,%01000000
.BYTE %00000100,%01000000
.BYTE %00001000,%01000000
.BYTE %00011000,%01000000
.BYTE %00100111,%11000000
.BYTE %01000000,%01000000
.BYTE %00000000,%01000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000 ;2
.BYTE %00000000,%00010000
.BYTE %00000000,%11100000
.BYTE %00000011,%00100000
.BYTE %00001100,%00100000
.BYTE %00110000,%01000000
.BYTE %11001000,%01000000
.BYTE %00000100,%10000000
.BYTE %00000010,%10000000
.BYTE %00000001,%00000000
.BYTE %00000001,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000 ;3
.BYTE %00000000,%00000000
.BYTE %00000000,%00000100
.BYTE %00000000,%01111000
.BYTE %00000011,%10010000
.BYTE %00111100,%00100000
.BYTE %00000100,%01000000
.BYTE %00000100,%10000000
.BYTE %00000011,%00000000
.BYTE %00000010,%00000000
.BYTE %00000100,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000 ;04
.BYTE %00000000,%00000000
.BYTE %00111100,%00000000
.BYTE %00000111,%10000000
.BYTE %00000100,%01110000
.BYTE %00000100,%00001111
.BYTE %00000100,%01110000
.BYTE %00000111,%10000000
.BYTE %00111100,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000 ;05
.BYTE %00000100,%00000000
.BYTE %00000010,%00000000
.BYTE %00000011,%00000000
.BYTE %00000100,%10000000
.BYTE %00000100,%01000000
.BYTE %00111100,%00100000
.BYTE %00000011,%10010000
.BYTE %00000000,%01111000
.BYTE %00000000,%00000100
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000001,%00000000 ;06
.BYTE %00000001,%00000000
.BYTE %00000010,%10000000
.BYTE %00000100,%10000000
.BYTE %11001000,%01000000
.BYTE %00110000,%01000000
.BYTE %00001100,%00100000
.BYTE %00000011,%00100000
.BYTE %00000000,%11100000
.BYTE %00000000,%00010000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%01000000 ;07
.BYTE %01000000,%01000000
.BYTE %00100111,%11000000
.BYTE %00011000,%01000000
.BYTE %00001000,%01000000
.BYTE %00000100,%01000000
.BYTE %00000010,%01000000
.BYTE %00000001,%01000000
.BYTE %00000000,%11000000
.BYTE %00000000,%01000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000
.BYTE %00010000,%00010000 ;08
.BYTE %00010000,%00010000
.BYTE %00001111,%11100000
.BYTE %00001000,%00100000
.BYTE %00000100,%01000000
.BYTE %00000100,%01000000
.BYTE %00000010,%10000000
.BYTE %00000010,%10000000
.BYTE %00000001,%00000000
.BYTE %00000001,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000100,%00000000 ;09
.BYTE %00000100,%00000100
.BYTE %00000111,%11001000
.BYTE %00000100,%00110000
.BYTE %00000100,%00100000
.BYTE %00000100,%01000000
.BYTE %00000100,%10000000
.BYTE %00000101,%00000000
.BYTE %00000110,%00000000
.BYTE %00000100,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000010,%00000000 ;0A
.BYTE %00000010,%00000000
.BYTE %00000101,%00000000
.BYTE %00000100,%10000000
.BYTE %00001000,%01001100
.BYTE %00001000,%00110000
.BYTE %00010000,%11000000
.BYTE %00010011,%00000000
.BYTE %00011100,%00000000
.BYTE %00100000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000 ;0B
.BYTE %00000000,%00100000
.BYTE %00000000,%01000000
.BYTE %00000000,%11000000
.BYTE %00000001,%00100000
.BYTE %00000010,%00100000
.BYTE %00000100,%00111100
.BYTE %00001001,%11000000
.BYTE %00011110,%00000000
.BYTE %00100000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000 ;0C
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00111100
.BYTE %00000001,%11100000
.BYTE %00001110,%00100000
.BYTE %11110000,%00100000
.BYTE %00001110,%00100000
.BYTE %00000001,%11100000
.BYTE %00000000,%00111100
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000 ;0D
.BYTE %00000000,%00000000
.BYTE %00100000,%00000000
.BYTE %00011110,%00000000
.BYTE %00001001,%11000000
.BYTE %00000100,%00111100
.BYTE %00000010,%00100000
.BYTE %00000001,%00100000
.BYTE %00000000,%11000000
.BYTE %00000000,%01000000
.BYTE %00000000,%00100000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000 ;0E
.BYTE %00100000,%00000000
.BYTE %00011100,%00000000
.BYTE %00010011,%00000000
.BYTE %00010000,%11000000
.BYTE %00001000,%00110000
.BYTE %00001000,%01001100
.BYTE %00000100,%10000000
.BYTE %00000101,%00000000
.BYTE %00000010,%00000000
.BYTE %00000010,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000 ;0F
.BYTE %00000100,%00000000
.BYTE %00000110,%00000000
.BYTE %00000101,%00000000
.BYTE %00000100,%10000000
.BYTE %00000100,%01000000
.BYTE %00000100,%00100000
.BYTE %00000100,%00110000
.BYTE %00000111,%11001000
.BYTE %00000100,%00000100
.BYTE %00000100,%00000000
.BYTE %00000000,%00000000
;*------------------------------------------------------*
;* PLAYER CRAFTS OF THRUST *
;*------------------------------------------------------*
.BYTE %00000000,%00000000 ;10
.BYTE %00000001,%00000000
.BYTE %00000001,%00000000
.BYTE %00000010,%10000000
.BYTE %00000010,%10000000
.BYTE %00000100,%01000000
.BYTE %00000100,%01000000
.BYTE %00001000,%00100000
.BYTE %00001111,%11100000
.BYTE %00010111,%11010000
.BYTE %00010011,%10010000
.BYTE %00000001,%00000000
.BYTE %00000000,%00000000 ;11
.BYTE %00000000,%01000000
.BYTE %00000000,%11000000
.BYTE %00000001,%01000000
.BYTE %00000010,%01000000
.BYTE %00000100,%01000000
.BYTE %00001000,%01000000
.BYTE %00011000,%01000000
.BYTE %00101111,%11000000
.BYTE %01000111,%01000000
.BYTE %00000110,%01000000
.BYTE %00000100,%00000000
.BYTE %00000000,%00000000 ;12
.BYTE %00000000,%00010000
.BYTE %00000000,%11100000
.BYTE %00000011,%00100000
.BYTE %00001100,%00100000
.BYTE %00110000,%01000000
.BYTE %11001000,%01000000
.BYTE %00011100,%10000000
.BYTE %00011110,%10000000
.BYTE %00111001,%00000000
.BYTE %00000001,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000 ;13
.BYTE %00000000,%00000000
.BYTE %00000000,%00000100
.BYTE %00000000,%01111000
.BYTE %00000011,%10010000
.BYTE %00111100,%00100000
.BYTE %00000100,%01000000
.BYTE %00001100,%10000000
.BYTE %00011111,%00000000
.BYTE %00110010,%00000000
.BYTE %00000100,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000 ;14
.BYTE %00000000,%00000000
.BYTE %00111100,%00000000
.BYTE %00000111,%10000000
.BYTE %00011100,%01110000
.BYTE %01111100,%00001111
.BYTE %00011100,%01110000
.BYTE %00000111,%10000000
.BYTE %00111100,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000 ;15
.BYTE %00000100,%00000000
.BYTE %00110010,%00000000
.BYTE %00011111,%00000000
.BYTE %00001100,%10000000
.BYTE %00000100,%01000000
.BYTE %00111100,%00100000
.BYTE %00000011,%10010000
.BYTE %00000000,%01111000
.BYTE %00000000,%00000100
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000001,%00000000 ;16
.BYTE %00111001,%00000000
.BYTE %00011110,%10000000
.BYTE %00011100,%10000000
.BYTE %11001000,%01000000
.BYTE %00110000,%01000000
.BYTE %00001100,%00100000
.BYTE %00000011,%00100000
.BYTE %00000000,%11100000
.BYTE %00000000,%00010000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000100,%00000000 ;17
.BYTE %00000110,%01000000
.BYTE %01000111,%01000000
.BYTE %00101111,%11000000
.BYTE %00011000,%01000000
.BYTE %00001000,%01000000
.BYTE %00000100,%01000000
.BYTE %00000010,%01000000
.BYTE %00000001,%01000000
.BYTE %00000000,%11000000
.BYTE %00000000,%01000000
.BYTE %00000000,%00000000
.BYTE %00000001,%00000000 ;18
.BYTE %00010011,%10010000
.BYTE %00010111,%11010000
.BYTE %00001111,%11100000
.BYTE %00001000,%00100000
.BYTE %00000100,%01000000
.BYTE %00000100,%01000000
.BYTE %00000010,%10000000
.BYTE %00000010,%10000000
.BYTE %00000001,%00000000
.BYTE %00000001,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%01000000 ;19
.BYTE %00000100,%11000000
.BYTE %00000101,%11000100
.BYTE %00000111,%11101000
.BYTE %00000100,%00110000
.BYTE %00000100,%00100000
.BYTE %00000100,%01000000
.BYTE %00000100,%10000000
.BYTE %00000101,%00000000
.BYTE %00000110,%00000000
.BYTE %00000100,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000 ;1A
.BYTE %00000010,%00000000
.BYTE %00000010,%01110000
.BYTE %00000101,%11100000
.BYTE %00000100,%11100000
.BYTE %00001000,%01001100
.BYTE %00001000,%00110000
.BYTE %00010000,%11000000
.BYTE %00010011,%00000000
.BYTE %00011100,%00000000
.BYTE %00100000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000 ;1B
.BYTE %00000000,%00100000
.BYTE %00000000,%01001100
.BYTE %00000000,%11111000
.BYTE %00000001,%00110000
.BYTE %00000010,%00100000
.BYTE %00000100,%00111100
.BYTE %00001001,%11000000
.BYTE %00011110,%00000000
.BYTE %00100000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000 ;1C
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00111100
.BYTE %00000001,%11100000
.BYTE %00001110,%00111000
.BYTE %11110000,%00111110
.BYTE %00001110,%00111000
.BYTE %00000001,%11100000
.BYTE %00000000,%00111100
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000 ;1D
.BYTE %00000000,%00000000
.BYTE %00100000,%00000000
.BYTE %00011110,%00000000
.BYTE %00001001,%11000000
.BYTE %00000100,%00111100
.BYTE %00000010,%00100000
.BYTE %00000001,%00110000
.BYTE %00000000,%11111000
.BYTE %00000000,%01001100
.BYTE %00000000,%00100000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000 ;1E
.BYTE %00100000,%00000000
.BYTE %00011100,%00000000
.BYTE %00010011,%00000000
.BYTE %00010000,%11000000
.BYTE %00001000,%00110000
.BYTE %00001000,%01001100
.BYTE %00000100,%11100000
.BYTE %00000101,%11100000
.BYTE %00000010,%01110000
.BYTE %00000010,%00000000
.BYTE %00000000,%00000000
.BYTE %00000000,%00000000 ;1F
.BYTE %00000100,%00000000
.BYTE %00000110,%00000000
.BYTE %00000101,%00000000
.BYTE %00000100,%10000000
.BYTE %00000100,%01000000
.BYTE %00000100,%00100000
.BYTE %00000100,%00110000
.BYTE %00000111,%11101000
.BYTE %00000101,%11000100
.BYTE %00000100,%11000000
.BYTE %00000000,%10000000
.END

151
OMEGA/omegattl

@ -0,0 +1,151 @@
.PAGE 'OMEGATTL'
;================================================================
;= =
;= PROGRAM-ID. OMEGA-RACE. =
;= =
;= AUTHOR. KEN-OHARA. =
;= EDITOR. KEN-OHARA. =
;= DATE-WRITTEN. 1982-05-17. =
;= LAST-EDITED. 1982-09-20. =
;= =
;================================================================
;
; PRODUCTS OF COMMODORE JAPAN CO.,LTD.
;
; TARGET-CPU 6510.
; VIDEO-CHIP 6566. (VIC)
; SOUND-CHIP 6581. (SID)
; I/O -CHIP 6526. (CIA)
;
;----- MEMORY MAP CONFIGURATION ------------------------------;
; ;
; 0000-00FF : ZERO PAGE RAM. ;
; 0100-01BF : WORKING RAM. ;
; 01C0-01FF : STACK. ;
; 0200-03FF : WORKING RAM. ;
; 0400-07F7 : SCREEN RAM OF CHARACTER INDEX. ;
; 07F8-07FF : SCREEN RAM OF SPRITE INDEX. ;
; 8000-9FFF : CARTRIDGE ROM. ;
; D000-D3FF : 6566. (VIC) ;
; D400-D7FF : 6581. (SID) SYNTHESIZER CHIP. ;
; D800-DBFF : SCREEN RAM OF CHARACTER COLOR. ;
; DC00-DCFF : 6526. (CIA) I/O CHIP. ;
; ;
;---------------------------------------------------------------;
;
.PAGE
;
;----- D000-D3FF 6556. (VIC) ---------------------------------;
; ;
;D000 SPRITE 0 X CMP ;
;D001 SPRITE 0 Y CMP ;
;D002 SPRITE 1 X CMP ;
;D003 SPRITE 1 Y CMP ;
;D004 SPRITE 2 X CMP ;
;D005 SPRITE 2 Y CMP ;
;D006 SPRITE 3 X CMP ;
;D007 SPRITE 3 Y CMP ;
;D008 SPRITE 4 X CMP ;
;D009 SPRITE 4 Y CMP ;
;D00A SPRITE 5 X CMP ;
;D00B SPRITE 5 Y CMP ;
;D00C SPRITE 6 X CMP ;
;D00D SPRITE 6 Y CMP ;
;D00E SPRITE 7 X CMP ;
;D00F SPRITE 7 Y CMP ;
;D010 SPRITE X CMP (MSB OF COORD.) ;
;D011 BIT 7 RASTER COMPARE ;
; BIT 6 EXTENDED COLOR MODE ;
; BIT 5 BIT MAP MODE ;
; BIT 4 UNUSED ;
; BIT 3 24/25 ROW SELECT (1=25 ROWS) ;
; BIT 2-0 SCROLL IN Y POSITION ;
;D012 (R/O) RASTER READ (RASTER CMP IRQ WRITE) ;
;D013 (R/O) LIGHT PEN LATCH X ;
;D014 (R/O) LIGHT PEN LATCH Y ;
;D015 SPRITE DISABLE (1=SPRITE ENABLED) ;
;D016 BIT 7-5 UNUSED ;
; BIT 4 MULTI-COLOR MODE ;
; BIT 3 38/40 COLUM SELECT (1=40 COL.) ;
; BIT 2-0 SCROLL IN X POSITION ;
;D017 SPRITE EXPAND IN "Y" ;
;D018 BIT 7-4 VIDEO MATRIX BASE ;
; BIT 3-1 CHARACTER SPACE BASE ;
;D019 BIT 7 FOLLOWING IRQ LINE ;
; BIT 2 IRQ FOR SPRITE TO SPRITE COLLISION ;
; BIT 1 IRQ FOR SPRITE TO BACKGROUND COLLISION ;
; BIT 0 RASTER CMP IRQ ;
;D01A IRQ MASK REGISTER (0=INTERRUPT DISABLED);
;D01B BACKGROUND TO SPRITE PRIORITY ;
;D01C MULTI-COLOR SPRITE SELECT ;
;D01D SPRITE EXPAND IN "X" ;
;D01E SPRITE TO SPRITE COLLISION DETECT ;
;D01F SPRITE TO BACKGROUND COLLISION DETECT ;
; COLOR REGISTERS (BIT 3-0) ;
;D020 BORDER COLOR ;
;D021 BACKGROUND COLOR 0 ;
;D022 BACKGROUND COLOR 1 ;
;D023 BACKGROUND COLOR 2 ;
;D024 BACKGROUND COLOR 3 ;
;D025 SPRITE MULTI-COLOR REGISTER 0 ;
;D026 SPRITE MULTI-COLOR REGISTER 1 ;
;D027 SPRITE 0 COLOR ;
;D028 SPRITE 1 COLOR ;
;D029 SPRITE 2 COLOR ;
;D02A SPRITE 3 COLOR ;
;D02B SPRITE 4 COLOR ;
;D02C SPRITE 5 COLOR ;
;D02D SPRITE 6 COLOR ;
;D02E SPRITE 7 COLOR ;
; ;
;---------------------------------------------------------------;
.PAGE
;
;----- D400-D7FF 6581. (SID) SYNTHSIZER CHIP -----------------;
; ;
;D400 FREQUENCY LO ;
;D401 FREQUENCY HI ;
;D402 PULSE WIDTH LO ;
;D403 BIT 7-4 UNUSED ;
; BIT 3-0 PULSE WIDTH HI ;
;D404 CONTROL REGISTER VOICE 1 ;
; BIT 7 NOISE ;
; BIT 6 PULSE ;
; BIT 5 SAWTOOTH ;
; BIT 4 TRIANGLE ;
; BIT 3 TEST BIT ;
; BIT 2 RING MOD ;
; BIT 1 SYNC ;
; BIT 0 GATE ;
;D405 BIT 7-4 ATTACK REGISTER ;
; BIT 3-0 DECAY REGISTER ;
;D406 BIT 7-4 SUSTAIN REGISTER ;
; BIT 3-0 RELEASE RESISTER ;
;D407-D40D CONTROL REGISTER VOICE 2 ;
; (FUNCTIONALLY IDENTICAL TO D400-D406) ;
;D40E-D414 CONTROL REGISTER VOICE 3 ;
; (FUNCTIONALLY IDENTICAL TO D400-D406) ;
;D415 CUTOFF FREQUENCY LO ;
;D416 CUTOFF FREQUENCY HI ;
;D417 BIT 7-4 RESONANCE OF FILTER ;
; BIT 3-0 SELECT SIGNALS TO BE ROUTED THROUGH ;
; FILTER BIT SET TO ZERO APPEAR DIRECTLY ;
; AT AUDIO OUTPUT, BITS SET TO 1 WILL BE ;
; PROCESSED THROUGH FILTER. ;
; BIT 3 EXTERNAL INPUT ;
; BIT 2 VOICE 3 ;
; BIT 1 VOICE 2 ;
; BIT 0 VOICE 1 ;
;D418 BIT 7-4 SELECT FILTER MODE AND OUTPUT OPTIONS. ;
; BIT 7 OFF ;
; BIT 6 HIGH PASS ;
; BIT 5 BAND PASS ;
; BIT 4 LOW PASS ;
; BIT 3-0 OUTPUT VOLUME ;
;D419 POT X ;
;D41A POT Y ;
;D41B OSCILLATOR 3/RANDAM NUMBER GENERATOR. ;
;D41C ENVELOPE 3 ;
; ;
;---------------------------------------------------------------;
.END

14
README.md

@ -137,8 +137,9 @@ Using [kernalemu](https://github.com/mist64/kernalemu) and [cbm6502asm](https://
| Directory | Year | Comments |
|--------------------------------------------------------------|------|-------------|
| [WIZARD](WIZARD) | 1982 | Wizard of Wor Ultimax Game |
| [KICKMAN](KICKMAN) | 1982 | Kickman Ultimax Game |
| [OMEGA](OMEGA) | 1982 | Omega Race Ultimax Game |
| [WIZARD](WIZARD) | 1982 | Wizard of Wor Ultimax Game |
## Descriptions
@ -416,13 +417,18 @@ The KIM-1 "KIMATH" math package (1976). Generated from the [original LST printou
The TIM (Terminal Interface Monitor) ROM (6530-004). Reconstructed from the [manual](http://archive.6502.org/books/mos_tim_terminal_interface_monitor_manual_mar_1976.pdf) by Martin Hoffmann-Vetter.
## KICKMAN
The game "Kickman" (1982) for the Ultimax. Reconstructed from the [BSO-format source](http://www.zimmers.net/anonftp/pub/cbm/src/c64/c64_kernal_bas_src.tar.gz).
## OMEGA
The game "Omega Race" (1982) for the Ultimax. Reconstructed from the [BSO-format source](http://www.zimmers.net/anonftp/pub/cbm/src/c64/c64_kernal_bas_src.tar.gz).
## WIZARD
The game "Wizard of Wor" (1982) for the Ultimax. Reconstructed from the [BSO-format source](http://www.zimmers.net/anonftp/pub/cbm/src/c64/c64_kernal_bas_src.tar.gz).
## KICKMAN
The game "Kickman" (1982) for the Ultimax. Reconstructed from the [BSO-format source](http://www.zimmers.net/anonftp/pub/cbm/src/c64/c64_kernal_bas_src.tar.gz).
# Credits

3
build.sh

@ -152,5 +152,6 @@ build2 ASSEMBLER_TED assembler
build1 DISK_MONITOR mon.lib
build1 MATHPACK mathpack
build1 WIZARD wizard
build1 KICKMAN kickman
build1 OMEGA omega
build1 WIZARD wizard

Loading…
Cancel
Save