CodeCombat 官方版

最近更新 热门排行

热门搜索:

当前位置:首页 ›› 其他软件 ›› 编程相关 ›› CodeCombat

CodeCombat 官方版

CodeCombat 官方版
  • 授权方式:免费软件
  • 软件类别:编程相关
  • 软件语言:简体中文
  • 软件大小:23.4 MB
  • 推荐星级:
  • 软件厂商:Home Page
  • 更新时间:2017-06-01 20:04
  • 网友评论:1  条
  • 运行环境:WinXP, Win2003, Vista, Win7, Win8, Win10
88.56%
11.44%
  • 本地下载文件大小:23.4 MB

  • 软件介绍
  • 软件截图
  • 相关文章
  • 下载地址
软件标签:

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

CodeCombat 官方版

软件特色

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

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

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

  • CodeCombat

精选推荐

软件评论

请自觉遵守互联网相关政策法规,评论内容只代表网友观点,与本站立场无关!

 
推荐软件