如何使用cxfreeze编译包含多个模块和文件的pygame项目?

时间:2016-08-03 15:02:29

标签: module pygame

所以,我是编程的新手,我做了一个PyGame项目,但我不知道如何编译它,我知道如何编译没有模块或多个文件的项目,但这只是打败了我。我到处搜索,我找不到任何可以帮助我的东西。 这是我在cx_freeze中尝试的代码,但是当我尝试运行程序时,它在cmd中给了我一个FileNotFounderror.Thank you!

来自cx_Freeze:

import setup,Executable

includefiles = ['alien.bmp', 'ship.bmp', 'music.mp3']
includes = ['alien.py','bullet.py','button.py','game_functions.py','game_stats.py','scoreboard.py','settings.py','ship.py',]
packages = ['pygame']

setup(
    name = 'Lupu Invasion',
    version = '0.1a',
    description = '',
    author = '',
    author_email = '',
    options = {'build_exe': {'packages':packages,'include_files':includefiles}},
    executables = [Executable('LupuInvasion.py')]

0 个答案:

没有答案