cssmagic / Learn-AI-Assisted-Python-Programming

📖 《AI 辅助编程》这本书的大本营。
137 stars 13 forks source link

[译] [1000] 第十章 开发小游戏 #16

Open cssmagic opened 6 months ago

cssmagic commented 6 months ago

10 Making Some Games

第十章 开发小游戏

This chapter covers

本章内容概要

There are many reasons why people learn to program. Some people want to automate tedious tasks as we did in the previous chapter. Some people want to work with artificial intelligence as we did in Chapter 7. Other people want to make interactive websites, Android or iOS apps, or Alexa skills. There’s an endless amount of stuff that programmers can make.

人们学习编程的理由千差万别。一些人希望能够像我们在上一章展示的那样,自动化那些重复性的任务。有些人则是想要像在第七章中那样,与人工智能进行合作。还有人愿意制作交互式网站、Android 或 iOS 应用程序,或是 Alexa 技能。程序员能够创造的东西实在是无穷无尽。

Another popular reason to learn programming is to create games. For that reason, we thought we’d end our Copilot programming journey with you by designing two small computer games. The first is a code-breaking game where you use clues to identify the computer’s secret number. The second is a two-player dice game where each player needs to balance risk and luck to reach the required number of points before the other player does. Instead of using graphics and animation, these games use text. We’ve made this decision to help us stay focused on the game logic, rather than the way that the game is represented or the way that the player interacts with the games. Along the way, we offer some next steps if you are interested in taking your game-making abilities further. And don’t worry, your current skills are a great start to that!

创造游戏是学习编程的另一个广受欢迎的原因。因此,我们打算通过设计两款小型计算机游戏,为你的 Copilot 编程之旅画上圆满的句号。第一款游戏是破解密码,通过线索揭开计算机隐藏的秘密数字。第二款是双人骰子游戏,玩家需要在对方之前,巧妙地权衡风险和运气以达到既定分数。选择文本而非图形和动画来展现这些游戏,是为了让我们能集中精力探讨游戏逻辑,而非游戏的视觉表现或是玩家的互动方式。如果你对提升游戏制作技能感兴趣,我们也会提供一些可能的后续步骤。不过,别担心,你目前所拥有的技能已经为此打下了良好的基础!


本章目录


本章正文略。如需阅读,请购买正版。


cssmagic commented 1 month ago

👉 想要更多译稿预览,请前往 总目录 中按章节阅读。