文件名称:procedureLoadRatSpr
-
所属分类:
- 标签属性:
- 上传时间:2012-11-16
-
文件大小:7.5kb
-
已下载:0次
-
提 供 者:
-
相关连接:无下载说明:别用迅雷下载,失败请重下,重下不扣分!
介绍说明--下载内容来自于网络,使用问题请自行百度
打地鼠游戏主要实现以下几部分:
1.用定时器实现老鼠的出现和隐没
在本例中,首先构造一些函数用于实现存放老鼠出现和隐没位置,然后通过定时器来加载这些数据。
2、 锤子不同状态的变化
在本例中,锤子有三种不同的状态:松开、敲击和击中。这三种状态与鼠标的OnMouseDown事件和OnMouseDown事件对应着。
3、 菜单以及相应图标事件的处理
主要用于实现游戏的重新开始、暂停、恢复或退出等事件,而图标对应的事件则除了实现一定的游戏功能外,还要对图标自身的更换处理。
-Hamster playing the game to achieve the following main sections: 1. Using timers to achieve the appearance of rats, and, hidden in this case, the first constructor function is used to implement a number of emerging and disappearing mouse storage location, and then through the timer to load the data . 2, hammer, the changes in different states in this case, the hammer, there are three different states: release, percussion, and hit. The three states with the mouse OnMouseDown events and OnMouseDown event corresponds. 3, and the corresponding icon in the menu of events to address key used to implement the game to restart, pause, resume or quit and so on, while the icon corresponding to the event, apart from a certain game features, but also the replacement of the icon itself treatment.
1.用定时器实现老鼠的出现和隐没
在本例中,首先构造一些函数用于实现存放老鼠出现和隐没位置,然后通过定时器来加载这些数据。
2、 锤子不同状态的变化
在本例中,锤子有三种不同的状态:松开、敲击和击中。这三种状态与鼠标的OnMouseDown事件和OnMouseDown事件对应着。
3、 菜单以及相应图标事件的处理
主要用于实现游戏的重新开始、暂停、恢复或退出等事件,而图标对应的事件则除了实现一定的游戏功能外,还要对图标自身的更换处理。
-Hamster playing the game to achieve the following main sections: 1. Using timers to achieve the appearance of rats, and, hidden in this case, the first constructor function is used to implement a number of emerging and disappearing mouse storage location, and then through the timer to load the data . 2, hammer, the changes in different states in this case, the hammer, there are three different states: release, percussion, and hit. The three states with the mouse OnMouseDown events and OnMouseDown event corresponds. 3, and the corresponding icon in the menu of events to address key used to implement the game to restart, pause, resume or quit and so on, while the icon corresponding to the event, apart from a certain game features, but also the replacement of the icon itself treatment.
(系统自动生成,下载前可以参看下载内容)
下载文件列表
procedureLoadRatSpr.doc
本网站为编程资源及源代码搜集、介绍的搜索网站,版权归原作者所有! 粤ICP备11031372号
1999-2046 搜珍网 All Rights Reserved.