我在空闲时间致力于游戏的开发,因为pygame不处理多点触控我正在使用kivy,但是当我想包含kivent_core以获得更好的性能时,我的游戏就停止在android上运行了。这是调试时终端显示的内容:
I/python (28331): [INFO ] [GL ] OpenGL parsed version: 2, 0
I/python (28331): [INFO ] [GL ] Texture max size <4096>
I/python (28331): [INFO ] [GL ] Texture max units <8>
I/python (28331): [INFO ] [Window ] auto add sdl2 input provider
I/python (28331): [INFO ] [Window ] virtual keyboard not allowed, single mode, not docked
I/python (28331): Traceback (most recent call last):
I/python (28331): File "/home/ivandg/Practica_1/main.py", line 4, in <module>
I/python (28331): File "/home/ivandg/.local/share/python-for-android/dists/unnamed_dist_1/private/lib/python2.7/site-packages/kivent_core/__init__.py", line 8, in <module>
I/python (28331): File "/home/ivandg/.local/share/python-for-android/dists/unnamed_dist_1/private/lib/python2.7/site-packages/kivent_core/rendering/__init__.py", line 3, in <module>
I/python (28331): File "kivent_core/systems/gamesystem.pxd", line 3, in init kivent_core.rendering.cmesh (kivent_core/rendering/cmesh.c:3798)
I/python (28331): File "/home/ivandg/.local/share/python-for-android/dists/unnamed_dist_1/private/lib/python2.7/site-packages/kivent_core/systems/__init__.py", line 1, in <module>
I/python (28331): File "kivent_core/managers/game_manager.pxd", line 3, in init kivent_core.systems.gamesystem (kivent_core/systems/gamesystem.c:4792)
I/python (28331): File "/home/ivandg/.local/share/python-for-android/dists/unnamed_dist_1/private/lib/python2.7/site-packages/kivent_core/managers/__init__.py", line 1, in <module>
I/python (28331): File "vertex_instructions.pxd", line 21, in init kivent_core.managers.resource_managers (kivent_core/managers/resource_managers.c:26770)
I/python (28331): ValueError: kivy.graphics.vertex_instructions.Mesh has the wrong size, try recompiling
I/python (28331): Python for android ended.
我使用python-for-android创建APK。
答案 0 :(得分:0)
我已经找到了解决方案,这就是我所做的:
buildozer -v android debug
在这里,我只是为像我这样的新手采取措施。 谢谢Kovak。