Assets from Eclipse "problem"

My problem occurs when I try to add a sprite to the folder “assets” that is within “proj.android”.

What I do is drag my image to that folder from eclipse, there all good copy me, but when I add it and try to do a test on my android eclipse I removed the image and when I run the application on my phone not open.

Someone could help me on this, thanks.

The assets folder is automatically generated based on the Resources folder. You want to add your images to the Resources folder that is at the same level as proj.android

yes @fekj97 everyone face these problems when the get into cocos2d-x
not at all a problem so dont worry… :smile:

First of all i would like to guide you with some suggestions.

  1. whenever you are importing some assets into your game, please check that those images are not locked or read-only.

  2. before importing an asset into the project check it’s properties and uncheck all the checkboxes at the bottom like read only etc etc, make everything unchecked.

  3. when that part if over, copy the assets that you want to add to your game and paste it in the resources folder not the assets folder okay… ??
    when you place it in the resources folder on the next build the assets are copied to assets folder in eclipse.

I believe everything should work fine for now.
If you still face some problems then reply to the post, or if it helped you hit a like… :smile:

Happy Coding :smile:

1 Like

From eclipse, delete the “assets” folder if it already exists (you may want to take a backup)

then

Select Project -> Right Click -> New-> Folder -> Advanced

Type assets in folder name and select Link to alternate location (Linked Folder) and type PARENT-1-PROJECT_LOC/Resources