1
0
mirror of https://github.com/fumiama/c64-snake.git synced 2026-06-05 00:32:39 +08:00
Files
c64-snake/head.asm
2021-04-03 19:34:32 +08:00

26 lines
578 B
NASM
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

.alias cblk $66 ; 边框
.alias csnk $a0 ; 像素
.alias csps $20 ; 空白
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; 按钮配置调试时使用WASD控制
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
.alias go_u 'W ;$55 ; 上
.alias go_d 'S ;$5f ; 下
.alias go_l 'A ;$1d ; 左
.alias go_r 'D ;$32 ; 右
.alias st_g 'P ;$a0 ; 开始/暂停
.alias ed_g 'Q ;$20 ; 结束
.data zp
.space d 1 ; 方向 值定义如上
.space c 1 ; 🐍长度 最大255 最小0
.space s 2 ; 得分 小端序
.data
.org $0400
.space title 40
.space field 960 ; 蛇所在屏幕内存区
.text