我在哪里可以找到Game
对象的常量列表,例如Game.HOSTILE_CREEPS
,Game.MOVE
和Game.ATTACK
?
问问题
2696 次
3 回答
5
它们可以在游戏文档中找到(页面底部)
常数
结果代码
Game.OK
0Game.ERR_NOT_OWNER
-1Game.ERR_NO_PATH
-2Game.ERR_NAME_EXISTS
-3Game.ERR_BUSY
-4Game.ERR_NOT_FOUND
-5Game.ERR_NOT_ENOUGH_ENERGY
-6Game.ERR_INVALID_TARGET
-7Game.ERR_FULL
-8Game.ERR_NOT_IN_RANGE
-9Game.ERR_INVALID_ARGS
-10Game.ERR_TIRED
-11Game.ERR_NO_BODYPART
-12Game.ERR_NOT_ENOUGH_EXTENSIONS
-13
Room.find() 常量
Game.CREEPS
1Game.MY_CREEPS
2Game.HOSTILE_CREEPS
3Game.SOURCES_ACTIVE
4Game.SOURCES
5Game.DROPPED_ENERGY
6Game.STRUCTURES
7Game.MY_STRUCTURES
8Game.HOSTILE_STRUCTURES
9Game.FLAGS
10Game.CONSTRUCTION_SITES
11Game.MY_SPAWNS
12Game.HOSTILE_SPAWNS
13Game.EXIT_TOP
14Game.EXIT_RIGHT
15Game.EXIT_BOTTOM
16Game.EXIT_LEFT
17
方向
Game.TOP
1Game.TOP_RIGHT
2Game.RIGHT
3Game.BOTTOM_RIGHT
4Game.BOTTOM
5Game.BOTTOM_LEFT
6Game.LEFT
7Game.TOP_LEFT
8
身体部位
Game.MOVE
“移动”Game.WORK
“工作”Game.CARRY
“携带”Game.ATTACK
“攻击”Game.RANGED_ATTACK
“远程攻击”Game.TOUGH
“艰难的”Game.HEAL
“愈合”
结构类型
Game.STRUCTURE_EXTENSION
“扩大”Game.STRUCTURE_RAMPART
“壁垒”Game.STRUCTURE_ROAD
“路”Game.STRUCTURE_SPAWN
“产卵”Game.STRUCTURE_WALL
“建筑墙”
颜色
Game.COLOR_RED
“红色的”Game.COLOR_PURPLE
“紫色的”Game.COLOR_BLUE
“蓝色的”Game.COLOR_CYAN
“青色”Game.COLOR_GREEN
“绿色”Game.COLOR_YELLOW
“黄色”Game.COLOR_ORANGE
“橙”Game.COLOR_BROWN
“棕色的”Game.COLOR_GREY
“灰色的”Game.COLOR_WHITE
“白色的”
房间模式
Game.MODE_SIMULATION
“模拟”Game.MODE_SURVIVAL
“生存”Game.MODE_WORLD
“世界”
于 2015-02-17T23:13:06.597 回答
0
于 2014-11-23T23:00:58.687 回答