Exporting A Libgdx Game as Executable Jar from Android Studio

一曲冷凌霜 提交于 2019-12-12 08:31:15

问题


Okay so I made a game using Libgdx and I intended it to be a android app(which is why i use android studio) but I want to let my friend without android phones try it out. The project is already setup for both desktop and android so is there any way to export this as a executable jar file?


回答1:


Type the command below in the terminal. Remember that you have to be in your LibGDX root directory, before issuing this command.

gradlew desktop:dist

More at: https://github.com/libgdx/libgdx/wiki/Gradle-on-the-Commandline#packaging-for-the-desktop




回答2:


You have to type

gradlew desktop:dist

command in Terminal in Android Studio. Then you should have an executable jar file in your project directory/desktop/build/libs.



来源:https://stackoverflow.com/questions/32302235/exporting-a-libgdx-game-as-executable-jar-from-android-studio

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!