Where to put shared resources? (to be included in Android and iOS apps)

Where should resources, those that are meant to be included in both the MOE iOS app and the Android app of a project, be placed within the project such that both targets have access to them and bundle them appropriately in each generated app? I’m thinking about images and support files, etc.

I thought I had seen documentation or read about this someplace, but maybe I was mistaken.


I realized that I’m thinking of LibGDX projects where shared resources are placed into an assets folder in the Android target.

Thus, I understand that resources should be added via Xcode. Is that correct?

In the ios-moe/xcode/ios-moe.xcodeproj/project.pbxproj

Hello Tian,
I can’t seem to find the path your are talking about,

here is my project.pbxproj.

project.pbxproj.zip (4.5 KB)

Can help me analyzing it?
It seems to be so different than what you show.

Thanks in Advance,
Sidhi Artha

Dear All,

when you have a libGDX project and are storing your resources in the Android target’s assets folder, then you need to set the MOE module’s main resource directory to that one:

sourceSets.main.resources.srcDirs = ["../android/assets"]

With this, instead of using resources from ios-moe/src/main/resources, android/assets will be used. If you need both these resource direcories, then use:

sourceSets.main.resources.srcDirs = ["src/main/resources", "../android/assets"]

These lines should be placed in your MOE module’s build.gradle file.

Best Regards,

1 Like