Building an app questions

Well i already asked for help in an older topic but i have not received any help… so here i am, well the thing is that I can build my app just fine (i’m using storyboard and corona v2012.12.8), and i have tried it on many cellPhones that works with corona (all of them androids) and all of them throw an error, so here is a list of questions about this matter:

1- I read that sound files must be in the root folder (where the main.lua file is located) or else the build is not going to work, are there another assets that follows the same rule?, also can you confirm this is true?

2- if i have files that are not required in the main.lua file that have syntax errors, do they affect the build of my app? if this is true why does it matter!? it’s not like the game is using those files.

3- having subfolders to organize my project affect the build of my app? (for example i always have an assets folder with images, sounds, etc. i also have the classes folder, scenes folder and so on), i ask this because all the sample projects have everything on the same root, i can’t imagine having to work on a big project like that, and the app i made threw me an error so i really can’t confirm this.

Any help on this is very much appreciated, i’m trying to get the best out of corona right now, also is it possible to debug my apps directly on my cellPhone and not in the simulator? it would help a lot since the simulator doesn’t behave the same… [import]uid: 141404 topic_id: 27033 reply_id: 327033[/import]

  1. That was a long long time ago. You can put everything but your main.lua flie in subdirectories now :slight_smile: (note for lua files you don’t use forward slashes, you use periods for instance: require(“code.module”) rather than require(“code/module”)

  2. They might not affect the build but would cause errors when changing to a scene that uses them (those errors should also show in the simulator)

  3. Same as above

Just be warned on devices they are case sensitive.

Trying to load an image that’s filename is “myImage.png” on a mac like this “myimage.png” will work but on device it will not.

Handy tip: use the console in the xcode organiser with your device attached and it will print out any warning/error messages, this will help you debug it :slight_smile: [import]uid: 84637 topic_id: 27033 reply_id: 109710[/import]

About xcode… i’m using windows, i’m developing for android… in that case is there any way to do that? [import]uid: 141404 topic_id: 27033 reply_id: 109715[/import]

Aha sure!

If you have installed the android sdk: http://developer.android.com/sdk/installing.html

Then you can simply use the following command in a terminal/command line window:

abd logcat  

That will give you the same information in the console/terminal window :slight_smile: [import]uid: 84637 topic_id: 27033 reply_id: 109721[/import]

Thanks Danny, i’ll try that =) [import]uid: 141404 topic_id: 27033 reply_id: 109723[/import]

Hey danny (or someone else), i used the assets in subfolders and i simply call them to a relative address from main.lua (like /assets/backgrounds/oliveBackground.png), if i do this then my build will not work on my device, so how do i do to make it work properly? right now i use all my assets in the root folder to make it work and it sucks =( [import]uid: 141404 topic_id: 27033 reply_id: 109832[/import]