我用 python 2.5 和 pygame 制作了一个游戏。
但是,我无法完成制作。因为发生了这个错误。
C:\Python26\TypeType\src\dist\Main.exe:8: RuntimeWarning: use font: MemoryLoadLibrary failed loading pygame\font.pyd
Traceback (most recent call last):
File "Main.py", line 8, in <module>
File "pygame\__init__.pyo", line 70, in __getattr__
NotImplementedError: font module not available
Traceback (most recent call last):
File "Main.py", line 8, in <module>
File "pygame\sysfont.pyo", line 253, in SysFont
RuntimeError: default font not found 'freesansbold.ttf'
也许我认为原因是因为它使用了一个名为 sysfont 的对象。(因为我的程序没有在执行文件上使用 sysfont 并且能够从没有安装 Python 的 PC 启动)出了什么问题。对不起,我是初学者。
编辑 我可以找到 Python2.5\Lib\site-packages\pygame\freesansbold.ttf
但是发生了同样的错误..我可以在哪里复制freesansbold.ttf