So I was using cx_Freeze in order to turn my python script using ursina into an executable but then this happened : Error
What am I supposed to do?
This is what my folder content and setup.py file looked like when I had the error : Content
So I was using cx_Freeze in order to turn my python script using ursina into an executable but then this happened : Error
What am I supposed to do?
This is what my folder content and setup.py file looked like when I had the error : Content
Try to add 'ursina'
to the packages
list of the build_exe_options
in the setup.py
script.
EDIT: try also to add src
to the include_files
list of the build_exe_options
:
build_exe_options = {'packages': ['ursina'], 'include_files': ['src']}
# ...
setup( name = ..., # complete!
...
options = {'build_exe': build_exe_options},
executables = [Executable(...)])
See the cx_Freeze documentation for further details.
From the original Ursina engine's folder copy the application.py
file and in the build folder, you will find exe.win-amd64-3.9
folder , inside that there will be a folder named lib
, inside that there will be ursina
folder you have to paste it here (if you are using default download location then this is the application.py's path: C:\Users\welcome\AppData\Local\Programs\Python\Python39\lib\site-packages\ursina\application.py
)