››其他软件››编程相关››CodeCombat
CodeCombat

CodeCombat 官方版

大小:23.4 MB系统:WinXP, Win2003, Vista, Win7, Win8, Win10

类别:编程相关时间:2017-06-01 20:04

  • CodeCombat

CodeCombat是一款极具挑战性的游戏平台,这里的所有游戏都是通过编程来玩的,支持Python、Javascript、CoffeeScript、Clojure、Lua、Io 等十几种编程语言,如果你是编程爱好者想提高自己技巧的话,可以玩这款游戏试试,时间长了肯定会大大地提高自己的编程水平的。

软件特色

游戏的每一关设计的都很巧妙,初期是一些基础知识的学习,让你对函数结构有个初步的认识,后面的关卡越来越难,判断、循环语句也会逐渐加入,需要自己更多的创造性,通过语法、接口编写出复杂的函数才能过关,玩家在不知不觉也就具备了编程的思维。

根据 XIao 的试玩后表示:“连英文苦手代码小白的我也能愉快地玩耍一晚上”,因此,估计大家即便无基础也都可以轻松上手的。

当然,由于 CodeCombat 是开源的,如果你本身已是开发高手,那么除了挑战一些高难度的多人游戏关卡之外,也可以完全参与到项目本身的开发中去,譬如代码编写、关卡设计、Bug测试、文字翻译等等,给 CodeCombat 这个公益项目做贡献。

游戏攻略

当牦牛靠近时向右移动10米来躲避

躲避4头牦牛完成此关

loop:

使用你的灵石获取你当前的 x 和 y 位置。

——x = self.pos.x

——y = self.pos.y

找到最近的耗牛。

——yak = self.findNearest(self.findEnemies())

使用 if 仅仅当牦牛少于10米距离的时候。

——if self.distanceTo(yak) < 10:

向右移动,添加10到你的x位置。

————x = x + 10

使用 moveXY 来移动!

————self.moveXY(x, y)

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(); }

为大家提供的是官方下载地址,请点击官方下载。

相关文章

热门推荐

同类排行榜

  1. 1双生幻想内购破解版167.5 MB
  2. 2迷你世界vivo渠道服929.7 MB
  3. 3汤姆猫跑酷单机版141.4 MB
  4. 4迷你世界oppo版929.7 MB
  5. 5决战平安京应用宝渠道服1.9 GB
  6. 6太空杀vivo版293.7 MB
  7. 7迷你枪战精英单机版1024 MB
  8. 8梦幻家园无限星无限金币版406.2 MB
  9. 9哈利波特魔法觉醒bilibili版1.8 GB
  10. 10饥饿鲨世界单机版324.8 MB

评论

我要跟帖
取消