简体   繁体   中英

Where to create the assets folder LibGDX Android Studio

I'm creating a game with android studio + libgdx, but it crashes with this logcat:

Exception in thread "LWJGL Application" com.badlogic.gdx.utils.GdxRuntimeException: Couldn't load file: bubbles.png

I'm following a tutorial, and it says to put the image in the assets folder, which i don't have...

I'm using LibGDX 1.0.0

In top of your studio select "Project" view, you will have your project structure. Navigate to main directory. If you do not see your assets folder, just right click on main and add a directory named "assets".

在此处输入图片说明

See this link for setting up your project: Using-libgdx-with-intellij-idea: linking-the-asset-directories

Personally, I am a fan of solution 3 and place the assets folder in the root folder next to the core/android/desktop/web project folders.

您可以在src/main/下创建资产文件夹。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM