codecombat之KithGard地牢1-18关代码分享
2015-08-22 13:51
686 查看
codecombat中国游戏网址:http://www.codecombat.cn/
所有代码为javascript代码分享
1、Kithgard地牢
// 向宝石进发。
// 小心撞墙!
// 在下面输入你的代码。
this.moveRight();
this.moveDown();
this.moveRight();
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2、深藏的宝石
// 利用你的移动命令收集所有宝石。
this.moveRight();
this.moveDown();this.moveUp();
this.moveUp();
this.moveRight();
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
3、幽灵守卫
// 避开食人魔的视线,夺取宝石。
this.moveRight();
this.moveUp();
this.moveRight();
this.moveDown();
this.moveRight();
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4、健忘的宝石匠
// 夺取宝石,然后到楼梯那里去。
this.moveRight();
this.moveUp();
this.moveRight();
this.moveRight();
this.moveDown();
this.moveDown();
this.moveUp();
this.moveRight();
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
5、真实姓名
// 抵抗Brak and Treg!
// 你必须攻击小食人魔两次。
this.moveRight();
this.attack("Brak");
this.attack("Brak");
this.moveRight();
this.attack("Treg");
this.attack("Treg");
this.moveRight();
this.moveRight();
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
6、有利的赔率
// 攻击食人魔并收集金币。
this.moveRight();
this.attack("Krug");
this.attack("Krug");
this.moveRight();
this.moveUp();
this.attack("Grump");
this.attack("Grump");
this.moveLeft();
this.moveLeft();
this.moveLeft();
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
7、Kounter Kithwise
// 避免食人魔和拿走宝石。
this.moveDown();
this.moveDown();
this.moveRight();
this.moveUp();
this.moveRight();
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
8、Kithgard的爬行之路
// 避免被食人魔看到.
this.moveRight();
this.moveLeft();
this.moveRight();
this.moveRight();
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
9、敌人的雷区
// 使用move 命令配合参数移动的更远。
this.moveRight(3);
this.moveUp();
this.moveRight();
this.moveDown(3);
this.moveRight(2);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
10、中断虚幻
// 使用诱饵分散守卫注意力在 X 位置
this.moveRight();
this.moveDown(2);
this.moveUp(2);
this.moveRight(3);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
11、高举之剑
// 打败食人魔
// 记住,每只攻击两次。
this.attack("Rig");
this.attack("Rig");
this.attack("Gurt");
this.attack("Gurt");
this.attack("Ack");
this.attack("Ack");
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
12、囚犯
// 从弱弱的门后面解救 Patrick
// 杀掉名为 Two 的守卫
// 得到宝石。
this.moveRight();
this.attack("Weak Door");
this.say("Hi!");
this.moveRight();
this.moveRight();
this.attack("Two");
this.attack("Two");
this.attack("Two");
this.attack("Two");
this.attack("Two");
this.attack("Two");
this.moveDown();
this.moveRight();
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
13、祸之火焰
// 食人魔看上去又大又慢,这种慢速移动能力帮你避免了致命进攻。
this.shield();
this.moveRight();
this.moveRight();
loop{
this.moveUp();
this.moveLeft();
this.moveDown();
this.moveRight();
}
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
14、Long Kithmaze
// This is a long maze...
this.moveRight(2);
this.moveUp(2);
this.moveRight(2);
this.moveUp(2);
this.moveRight(2);
this.moveUp(2);
// Now you'll have to repeat the above steps two more times to get to the end of the maze...
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
15、闹鬼迷宫
// loop 让你更容易地反复做事。
loop {
// 在这里添加命令来重复。
this.moveRight(2);
this.moveUp(2);
}
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
16、谜一般的Kithmaze
// loops 让你更容易地反复做事。
loop {
// 此处添加loop循环的代码。
this.moveRight();
this.moveDown();
this.moveRight();
this.moveRight();
this.moveUp();
}
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
17、更近一步
// 使用少于四行代码穿越迷宫
loop {
this.moveRight(2);
this.moveDown();
}
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
18、再次迷宫历险
// 使用loop循环穿越迷宫!
loop {
this.moveRight();
this.moveUp();
this.moveRight();
this.moveDown();
}
所有代码为javascript代码分享
1、Kithgard地牢
// 向宝石进发。
// 小心撞墙!
// 在下面输入你的代码。
this.moveRight();
this.moveDown();
this.moveRight();
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2、深藏的宝石
// 利用你的移动命令收集所有宝石。
this.moveRight();
this.moveDown();this.moveUp();
this.moveUp();
this.moveRight();
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
3、幽灵守卫
// 避开食人魔的视线,夺取宝石。
this.moveRight();
this.moveUp();
this.moveRight();
this.moveDown();
this.moveRight();
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4、健忘的宝石匠
// 夺取宝石,然后到楼梯那里去。
this.moveRight();
this.moveUp();
this.moveRight();
this.moveRight();
this.moveDown();
this.moveDown();
this.moveUp();
this.moveRight();
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
5、真实姓名
// 抵抗Brak and Treg!
// 你必须攻击小食人魔两次。
this.moveRight();
this.attack("Brak");
this.attack("Brak");
this.moveRight();
this.attack("Treg");
this.attack("Treg");
this.moveRight();
this.moveRight();
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
6、有利的赔率
// 攻击食人魔并收集金币。
this.moveRight();
this.attack("Krug");
this.attack("Krug");
this.moveRight();
this.moveUp();
this.attack("Grump");
this.attack("Grump");
this.moveLeft();
this.moveLeft();
this.moveLeft();
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
7、Kounter Kithwise
// 避免食人魔和拿走宝石。
this.moveDown();
this.moveDown();
this.moveRight();
this.moveUp();
this.moveRight();
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
8、Kithgard的爬行之路
// 避免被食人魔看到.
this.moveRight();
this.moveLeft();
this.moveRight();
this.moveRight();
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
9、敌人的雷区
// 使用move 命令配合参数移动的更远。
this.moveRight(3);
this.moveUp();
this.moveRight();
this.moveDown(3);
this.moveRight(2);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
10、中断虚幻
// 使用诱饵分散守卫注意力在 X 位置
this.moveRight();
this.moveDown(2);
this.moveUp(2);
this.moveRight(3);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
11、高举之剑
// 打败食人魔
// 记住,每只攻击两次。
this.attack("Rig");
this.attack("Rig");
this.attack("Gurt");
this.attack("Gurt");
this.attack("Ack");
this.attack("Ack");
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
12、囚犯
// 从弱弱的门后面解救 Patrick
// 杀掉名为 Two 的守卫
// 得到宝石。
this.moveRight();
this.attack("Weak Door");
this.say("Hi!");
this.moveRight();
this.moveRight();
this.attack("Two");
this.attack("Two");
this.attack("Two");
this.attack("Two");
this.attack("Two");
this.attack("Two");
this.moveDown();
this.moveRight();
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
13、祸之火焰
// 食人魔看上去又大又慢,这种慢速移动能力帮你避免了致命进攻。
this.shield();
this.moveRight();
this.moveRight();
loop{
this.moveUp();
this.moveLeft();
this.moveDown();
this.moveRight();
}
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
14、Long Kithmaze
// This is a long maze...
this.moveRight(2);
this.moveUp(2);
this.moveRight(2);
this.moveUp(2);
this.moveRight(2);
this.moveUp(2);
// Now you'll have to repeat the above steps two more times to get to the end of the maze...
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
15、闹鬼迷宫
// loop 让你更容易地反复做事。
loop {
// 在这里添加命令来重复。
this.moveRight(2);
this.moveUp(2);
}
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
16、谜一般的Kithmaze
// loops 让你更容易地反复做事。
loop {
// 此处添加loop循环的代码。
this.moveRight();
this.moveDown();
this.moveRight();
this.moveRight();
this.moveUp();
}
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
17、更近一步
// 使用少于四行代码穿越迷宫
loop {
this.moveRight(2);
this.moveDown();
}
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
18、再次迷宫历险
// 使用loop循环穿越迷宫!
loop {
this.moveRight();
this.moveUp();
this.moveRight();
this.moveDown();
}
相关文章推荐
- python学习笔记一
- c# 隐藏已打开的窗口,打开登陆窗口
- 数字大小写转换PHP代码
- Qt中进度条 和进度对话框的典型使用方法
- C语言求素数的算法
- 20位活跃在Github上的国内技术大牛(走进技术大咖的世界)
- Python 基础语法(一)
- 算法导论—无向图的遍历(BFS+DFS,MATLAB)
- Python爬虫之正则表达式
- How to run java and junit in command line
- windows7 配置 python开发环境
- C++中将string类型转换为int, float, double类型 主要通过以下几种方式:
- java Map,Set,List的区别
- C++ int类型转换string类型
- C++常见面试
- Javamail发送邮件的简单实例
- java中的equals和==
- java 对象和引用
- java 访问权限控制
- java中的hashcode方法