汇编样例程序.doc

汇编样例程序

stack segment db 512 dup(?) stack ends data segment infol db 0dh,0ah,input 1,2,3:(1:bird,2:che,3:exit) $ data ends code segment assume cs:code,ds:data,ss:stack start: mov ax,data mov ds,ax mov ah,0;设置显示方式为320*200彩色图形方式 mov al,04h int 10h ;设置显示方式 mov ah,0bh;设置背景色 mov bh,0;非0为没有背景色 mov bl,1;背景为蓝色 int 10h lea dx,infol mov ah,9 int 21h mov ah,0 int 16h;键盘中断 cmp al,31h jnz b call xiao b:cmp al,32h jnz finish call che xiao proc near;小鸟主程序 mov cx,0b0h;小鸟初始位置 mov dx,64h ;1---------------------------------------------动画实现核心部分 draw1: call clear call bird;调用小鸟子程序 ;---------------------------------------

文档评论(0)

1亿VIP精品文档

相关文档