Pygame
原作者 | Lenard Lindstrom, René Dudfield, Pete Shinners, Nicholas Dudfield, Thomas Kluyver, and others[1] |
---|---|
開發者 | Pygame Community |
初始版本 | 2000年10月28號[2][3] |
最新發布 | 2.5.0 / 2023年6月24號[4] |
程式語言 | Python, C, Cython, and Assembly[5][6] |
作業系統 | Cross-platform |
軟件類別 | API |
許可協議 | GNU Lesser General Public License |
庫 |
Pygame(可以借入粵語做粵拼:paai1 gem1)係一系列跨平台嘅 Python 模塊,專門設計嚟寫遊戲程式嘅。
主要功能[編輯]
- 初始化:
import pygame # 同部電腦講,要用 pygame 呢個 module。 pygame.init() # 同 pygame 啲 module 做初始化。
- 產生遊戲嘅圖像:
pygame.display.set_mode((400, 500)) # 開個 400 × 500 像素咁大嘅 window (win1 dou4)
事件處理[編輯]
睇埋:事件驅動編程
背景[編輯]
睇埋:Python 程式語言
睇吓[編輯]
參攷[編輯]
- ↑ "Contributors to Pygame". GitHub.
- ↑ Shinners, Pete. "Python Pygame Introduction - History". Pygame.org. 原著喺2019-09-17歸檔. 喺2017-04-28搵到.
- ↑ "Downloads - Pygame - Python game development". Pypi.python.org.
- ↑ "Delicious but a weird". www.pygame.org. 喺2023-09-13搵到.
- ↑ "About Pygame". GitHub. 原著喺18 September 2019歸檔. 喺31 August 2019搵到.
- ↑ "GettingStarted". Pygame.org.
外拎[編輯]
- PyGame Tutorial, GeeksForGeeks (英文)