collider by Kuemmel [web] & Sensenstahl [web]
[nfo]
|
||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
||||||||||||||
|
popularity : 49% |
|||||||||||||
alltime top: #40564 |
|
|||||||||||||
|
||||||||||||||
added on the 2021-03-14 19:23:52 by sensenstahl |
popularity helper
comments
neat! \o/
rulez added on the 2021-03-14 19:24:26 by HellMood
the best way to learn the palette order
ouch. but sound!
I've taken out the sound and pared it down to 128 bytes.
Can I post asm here?
Can I post asm here?
cpu 8086 ; Collider Trimmed
org 0x100 ; nasm
;21:21 2022-10-19 128 published code
; trimmed from from sensenstahl's collider that was 256 bytes
; (OK that had sounds as well!)
; Esc=Exit, other key = change colour
; on collision get 123/7Bh points if same colour
Start:
mov al,03
int 10h
mov bh,0B8h
push bx
pop ds
mov al,0DBh
mov cl,050h
PutScrn:
mov [di+0642h],al
mov [di+06E2h],ax
mov [di+0782h],al
scasw
loop PutScrn
UpScore:
AddOne:
mov di,08B0h
PutCnt:
dec di
dec di
mov ax,0A30h
xchg ax,[di]
jcxz EndCnt
or al,30h
inc ax
cmp al,3Ah
jz PutCnt
mov [di],al
loop AddOne
EndCnt:
in al,40h
mul di
and ax,0F0Fh
mov bx,ax
and al,ah
jz EndCnt
mov di,075Dh
mov si,0701h
inc cx
NoKey:
loop Frame
mov cl,0Bh
mov [si],ch
lodsw
mov [di],ch
dec di
dec di
cmp di,si
jz YouWin
Frame:
mov [di],bh
mov [si],bl
mov dx,03DAh
vsync1:
in al,dx
test al,8
jnz vsync1
vsync2:
in al,dx
test al,8
jz vsync2
mov ah,1
int 16h
jz NoKey
cbw
int 16h
NewClr:
inc bx
and bl,0Fh
jz NewClr
cmp al,1Bh
jnz NoKey
YouWin:
mov cl,7Bh
cmp bl,bh
jz UpScore
ret
org 0x100 ; nasm
;21:21 2022-10-19 128 published code
; trimmed from from sensenstahl's collider that was 256 bytes
; (OK that had sounds as well!)
; Esc=Exit, other key = change colour
; on collision get 123/7Bh points if same colour
Start:
mov al,03
int 10h
mov bh,0B8h
push bx
pop ds
mov al,0DBh
mov cl,050h
PutScrn:
mov [di+0642h],al
mov [di+06E2h],ax
mov [di+0782h],al
scasw
loop PutScrn
UpScore:
AddOne:
mov di,08B0h
PutCnt:
dec di
dec di
mov ax,0A30h
xchg ax,[di]
jcxz EndCnt
or al,30h
inc ax
cmp al,3Ah
jz PutCnt
mov [di],al
loop AddOne
EndCnt:
in al,40h
mul di
and ax,0F0Fh
mov bx,ax
and al,ah
jz EndCnt
mov di,075Dh
mov si,0701h
inc cx
NoKey:
loop Frame
mov cl,0Bh
mov [si],ch
lodsw
mov [di],ch
dec di
dec di
cmp di,si
jz YouWin
Frame:
mov [di],bh
mov [si],bl
mov dx,03DAh
vsync1:
in al,dx
test al,8
jnz vsync1
vsync2:
in al,dx
test al,8
jz vsync2
mov ah,1
int 16h
jz NoKey
cbw
int 16h
NewClr:
inc bx
and bl,0Fh
jz NewClr
cmp al,1Bh
jnz NoKey
YouWin:
mov cl,7Bh
cmp bl,bh
jz UpScore
ret
submit changes
if this prod is a fake, some info is false or the download link is broken,
do not post about it in the comments, it will get lost.
instead, click here !