工具与资源github.com
Pyxel:Python 复古游戏开发环境
Pyxel: A retro game development environment in Python
2018 — 2024,它一次次回到首页
黑点是上首页(≥ 50 分)的那次投稿,空心点是没冲上去的投稿,点越大分数越高。
导读
Pyxel 是一个用 Python 打造的复古游戏开发环境,灵感来自 Pico-8 等幻想游戏机,让开发者用简单的像素图形和音频规格快速制作小游戏。它降低了游戏编程的门槛,适合初学者和想快速验证点子的开发者。
为什么经久不衰:它把 80 年代游戏开发的简单心智模型带回 Python 生态,是入门游戏编程和教学的经典工具,多年后依然活跃。
HN 评论精选
介绍 Pico-8 这一灵感来源,并推荐它作为简单游戏编程的绝佳工具
很多人可能不了解,介绍一下 Pyxel README 中提到的灵感来源 Pico-8——一款“幻想游戏机”。它开创了简易游戏引擎的潮流,也是其中最流行的。今年的热门游戏《Celeste》最初就是 Pico-8 游戏。Pico-8 提供 Lua API、内置的 8x8 像素图形编辑器和 4 通道音频编辑器,游戏可导出为 PC/Mac/Linux 可执行文件、网页 HTML+JS,甚至一张 PNG 图片方便分享。它还有非常活跃的 BBS 可以在线玩别人分享的“卡带”。我是个编程新手,以前在现代机器上做个简单游戏太麻烦了——不想为了验证个点子就搭 Unity 项目或学 OpenGL。我一直在用 Pico-8 做简单的游戏编程,非常推荐。
aquova查看英文原文
Since it seems that many people here are unaware, so let me introduce Pico-8, the "Fantasy Video Game console" that is referenced in Pyxel's README as an inspiration: https://www.lexaloffle.com/pico-8.php Pico-8 is (AFAIK) the program that kicked off a trend of simple game engines, and it is by far the most popular. A popular game that came out this year, Celeste, was originally a Pico-8 game that proved popular enough to remake in a more modern game engine. Pico-8 supports a Lua API, with a built-in graphics editor for 8x8 sprites, and a 4-channel audio editor. Games can be exported as a PC/Mac/Linux binary, into HTML+JS for embedding into a webpage, and even as a PNG for easy sharing to other users with the Pico-8 program. There's also a very active BBS where 'cartridges' can be shared and played online: https://www.lexaloffle.com/bbs/?cat=7#mode=carts I'm a relatively novice programmer, and one of the things that frustrated me was how difficult it was to make a simple game on modern machines. I didn't want to have to set up a whole Unity project or dive into OpenGL just for a little proof of concept. I've been heavily using Pico-8 and really recommend it for simple game programming. There's also a hashtag on Twitter (if you're into that sort of thing), #pico8, where people try to create interesting visual code golf programs that fit into the size of a Tweet, then they post the source code and a gif.
复古开发环境的小心智模型是学习编程基本原理的好途径
很适合学习游戏编程。80、90 年代的开发环境非常简单,你必须亲自控制屏幕上的每一个像素,因此只需学习一个很小的编程心智模型,其余一切都由你自己设计。而且原始硬件和无需考虑可移植性,意味着你只需关注一两种平台组合。这能帮助年轻开发者理解基本原理,一窥那些现代全能游戏引擎表面之下的运作方式。
TuringTest查看英文原文
Cool for learning to program games. Development environments in the 80's and 90's were so simple that you had to program down to every pixel shown on the screen (well, maybe calling some line and sprite primitives for speed), so you only needed to learn a small mental model for programming, and everything above it was designed by you. Also, the primitive hardware and no expectations of portability meant that you only had to care about one or two combinations of platforms (maybe supporting a small range of graphics and sound cards). This can help teach younger developers to understand the basic principles, and get a glimpse of how things are done below the surface of those modern do-it-all gaming engines.
简单引擎让年轻人能做出可玩的游戏,重燃对编程的兴趣
我打算花点时间玩玩这个……我认为简单的游戏引擎对吸引年轻人进入编程非常重要。我有两个继子(11 岁和 17 岁),都喜欢玩游戏,但大儿子十一二岁时曾对编程有点兴趣。问题在于他们玩的游戏与他们能指望编出来的东西相差太远——如果让他们看到编程一个 FPS 需要什么,他们(可以理解地)会气馁并转向别处。而这样的工具能让他们做出可玩的东西(复古游戏在他们眼里还很酷),真正学到东西,并看到一条前进的道路。我像他们这么大时,Manic Miner 这样的游戏看起来是可能做出来的,而今天的游戏需要数千人年,像不可能的外星科技。
djaychela查看英文原文
Having had a quick look through, I think I'm going to spend some time playing around with this... I think that simple game engines are really important to getting young people into programming. I have two step-sons (11 and 17), both of who are into gaming, but the elder one showed a bit of interest in programming when he was 11-12, but the problem (I think) is that the games they are playing are light-years away from anything they can even hope to program - and if they see what's involved in programming a FPS, they are (understandably!) crestfallen and look elsewhere. However, something like this would give them a way in to program something playable (and retro games are cool as far as they're concerned), but do some genuine learning AND see that there may be a path forward for them to produce something worthwhile. When I was their age, games like Manic Miner seemed possible. I'm not in any way saying I had the skill of Matthew Smith (and still don't, I'm learning myself for a career change), but it didn't seem like impossible future alien technology, whereas today's games are - they take thousands of man years to create, and are made by incredibly skilled people.
推荐 LOVE 等其他易用的 2D 框架,并指出命名撞车问题
看起来真不错,可惜名字和现有应用 Pyxel Edit 太相似了。我现在最喜欢的 2D 框架是 LOVE(love2d.org),我正在用它和我的孩子们一起做东西,用起来非常愉快。我也喜欢 Monkey-2,但只在想做基础 3D 时用它,因为 LOVE 的 2D 已经做得很好。
adrianoconnor查看英文原文
This looks really nice. It's a shame the name is so similar to an existing app though (Pyxel Edit, https://pyxeledit.com/) My favourite 2D framework right now is is LOVE (love2d.org) - I'm using that to build stuff with/for my kids and it's just a joy to use. I'll probably write up some parent/child friendly tutorials at some point. I also like Monkey-2 (http://monkeycoder.co.nz/), but I only really use that when I want to do basic 3D stuff, because Love does the 2D stuff so well...
历次讨论
同类还值得读
直接在浏览器中启动 Linux 内核
Boot a linux kernel right inside your browser.
Fabrice Bellard 的 JSLinux 页面,用 JavaScript 在浏览器里启动一个 Linux 内核,并提供一个可交互的终端环境。
工具与资源上首页 5 次 · 2011–2025bellard.orgHacker News 未公开功能与行为清单(2018)
A List of Hacker News's Undocumented Features and Behaviors (2018)
数据科学家 Max Woolf 整理的 Hacker News 未公开功能与行为清单,涵盖投票机制、排名算法、账号惩罚等社区运作细节。
工具与资源上首页 5 次 · 2019–2025github.comMapSCII:在终端中用盲文和 ASCII 渲染地图
MapSCII – Braille and ASCII map renderer for the console
MapSCII 是一个在命令行终端里渲染地图的开源工具,用盲文字符和 ASCII 字符把地理数据画成可交互浏览的字符地图。
工具与资源上首页 5 次 · 2017–2025github.com顶尖大学的免费在线课程
Free Online Courses from Top Universities
Open Culture 整理的一份免费在线课程合集,汇集了全球顶尖大学(如 MIT、斯坦福、耶鲁等)向公众开放的网络课程资源,涵盖音频、视频等多种形式。
工具与资源上首页 5 次 · 2010–2022openculture.com淘气字符串:容易引发用户输入问题的字符串清单
Naughty Strings: A list of strings likely to cause issues as user-input data
一个 GitHub 仓库,收录了大量容易让程序出问题的用户输入字符串,如特殊字符、emoji、SQL 注入片段、系统命令等,供开发者用于测试输入处理逻辑。
工具与资源上首页 4 次 · 2015–2020github.com