cx_Freeze 编译 Python & Pygame 文档为 .exe 文件时出现奇怪的错误
Got a weird error with cx_Freeze compiled Python & Pygame Document as a .exe file
我正在使用 Python 2.7 和 Pygame 1.9 创建视频游戏。我用 cx_Freeze 4.3.4 编译了它。当我 运行 .exe 文件时,出现此错误:
Fatal Python error: (pygame parachute) Segmentation Fault
This application has requested the Runtime to terminate it in an unusual way.
Please contact the application's support team for more information.
我浏览了整个网络和这个网站,但没有找到任何可以真正帮助我的东西。我使用默认的 pygame 字体。所以字体不行。
如果这有帮助,我将其制作成 32 位格式。您可以在下面找到源代码。
可以找到 Python 源代码 here。
可以找到所有资产 here。
感谢你的时间,OrionDark7。
刚想通了,果然是字体问题。而不是:
pygame.font.Font(None, 1)
应该是:
pygame.font.Font("Font Filepath and Filename here", 1)
对不起,如果我浪费了你的时间。只是想弄明白。
我正在使用 Python 2.7 和 Pygame 1.9 创建视频游戏。我用 cx_Freeze 4.3.4 编译了它。当我 运行 .exe 文件时,出现此错误:
Fatal Python error: (pygame parachute) Segmentation Fault
This application has requested the Runtime to terminate it in an unusual way.
Please contact the application's support team for more information.
我浏览了整个网络和这个网站,但没有找到任何可以真正帮助我的东西。我使用默认的 pygame 字体。所以字体不行。
如果这有帮助,我将其制作成 32 位格式。您可以在下面找到源代码。
可以找到 Python 源代码 here。
可以找到所有资产 here。
感谢你的时间,OrionDark7。
刚想通了,果然是字体问题。而不是:
pygame.font.Font(None, 1)
应该是:
pygame.font.Font("Font Filepath and Filename here", 1)
对不起,如果我浪费了你的时间。只是想弄明白。