gpt4 book ai didi

android - libgdx 游戏无法在安卓手机上运行

转载 作者:行者123 更新时间:2023-11-29 18:09:51 29 4
gpt4 key购买 nike

我正在尝试从这个基于 libgdx 的游戏构建安卓游戏但是当我从 http://rengelbert.com/blog/downloads/froggerLibGDXSource.zip 下载的 libgdx 代码移植到安卓游戏时安卓应用程序崩溃了

我已经为这个游戏构建了 android 代码,你可以从这里 https://rapidshare.com/files/3456268683/FroggerLibGDXAndroid.zip 下载它

游戏崩溃无法启动请帮助我将游戏移植到安卓

这是我收到的错误信息

/AndroidRuntime( 2966): >>>>>>>>>>>>>> AndroidRuntime START <<<<<<<<<<<<<<
/AndroidRuntime( 2966): CheckJNI is ON
/AndroidRuntime( 2966): --- registering native functions ---
/ActivityManager( 65): Starting activity: Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER
/AndroidRuntime( 2966): Shutting down VM
/dalvikvm( 2966): Debugger has detached; object registry had 1 entries
/AndroidRuntime( 2966): NOTE: attach of thread 'Binder Thread #3' failed
/ActivityManager( 65): Start proc com.libgdx.screen for activity com.libgdx.screen/.LibgdxScreenAndroidActivity: pid=29
/dalvikvm( 2973): Trying to load lib /data/data/com.libgdx.screen/lib/libgdx.so 0x43e37a00
/dalvikvm( 2973): Added shared lib /data/data/com.libgdx.screen/lib/libgdx.so 0x43e37a00
/dalvikvm( 2973): No JNI_OnLoad found in /data/data/com.libgdx.screen/lib/libgdx.so 0x43e37a00, skipping init
/dalvikvm( 303): GC_EXPLICIT freed 1722 objects / 57656 bytes in 13322ms
/qemud ( 38): fdhandler_accept_event: accepting on fd 10
/qemud ( 38): created client 0x1073a8 listening on fd 15
/qemud ( 38): client_fd_receive: attempting registration for service 'sensors'
/qemud ( 38): client_fd_receive: -> received channel id 17
/qemud ( 38): client_registration: registration succeeded for client 17
/qemud ( 38): fdhandler_event: disconnect on fd 15
/AndroidInput( 2973): sensor listener setup
/libEGL ( 2973): egl.cfg not found, using default config
/QemuSensors( 65): data__poll: len=-1, errno=9: Bad file number
/QemuSensors( 65): data__poll: len=-1, errno=9: Bad file number
/libEGL ( 2973): loaded /system/lib/egl/libGLES_android.so
/QemuSensors( 65): data__poll: len=-1, errno=9: Bad file number
/QemuSensors( 65): data__poll: len=-1, errno=9: Bad file number
/QemuSensors( 2973): data__poll: len=-1, errno=9: Bad file number
/ActivityManager( 65): Launch timeout has expired, giving up wake lock!
/QemuSensors( 65): data__poll: len=-1, errno=9: Bad file number
/QemuSensors( 65): data__poll: len=-1, errno=9: Bad file number
/AndroidGraphics( 2973): OGL renderer: Android PixelFlinger 1.3
/ActivityManager( 65): Displayed activity com.libgdx.screen/.LibgdxScreenAndroidActivity: 10258 ms (total 10258 ms)
/AndroidGraphics( 2973): OGL vendor: Android
/AndroidGraphics( 2973): OGL version: OpenGL ES-CM 1.0
/AndroidGraphics( 2973): OGL extensions: GL_OES_byte_coordinates GL_OES_fixed_point GL_OES_single_precision GL_OES_read_f
/AndroidGraphics( 2973): framebuffer: (5, 6, 5, 0)
/AndroidGraphics( 2973): depthbuffer: (16)
/AndroidGraphics( 2973): stencilbuffer: (0)
/AndroidGraphics( 2973): samples: (0)
/AndroidGraphics( 2973): coverage sampling: (false)
/QemuSensors( 65): data__poll: len=-1, errno=9: Bad file number
/QemuSensors( 65): data__poll: len=-1, errno=9: Bad file number
/ActivityManager( 65): Activity idle timeout for HistoryRecord{43f692f8 com.libgdx.screen/.LibgdxScreenAndroidActivity}
/dalvikvm( 2973): GC_EXTERNAL_ALLOC freed 1740 objects / 111376 bytes in 1622ms
/QemuSensors( 2973): data__poll: len=-1, errno=9: Bad file number
/AndroidGraphics( 2973): Managed meshes/app: { }
/AndroidGraphics( 2973): Managed textures/app: { }
/AndroidGraphics( 2973): Managed shaders/app: { }
/AndroidGraphics( 2973): Managed buffers/app: { }
/QemuSensors( 65): data__poll: len=-1, errno=9: Bad file number
/QemuSensors( 65): data__poll: len=-1, errno=9: Bad file number

最佳答案

请试试这个,看看它是否解决了崩溃问题:

转到 Android 项目的属性,确保正在导出 Jar 和桌面项目。检查 Java Build Path -> Order and Export 是否如下所示:

enter image description here

如果您想使用不同于 4.1 的 Android 版本,那很好(我只是没有安装其他版本,所以我将其更改为 4.1)。

关于android - libgdx 游戏无法在安卓手机上运行,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11346331/

29 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com