managed to get out first corona game

Its a girls dressup game, contentwise its not that rich yet, take a look, it has decent graphics:

http://itunes.apple.com/us/app/igirls-dressup/id531003169?mt=8

will try to add more content to it. [import]uid: 13099 topic_id: 27220 reply_id: 327220[/import]

Hey I downloaded to check it out but it won’t open on my iPod touch. iOS version 5.0.1.

All I see is the loading screen and then it goes black and it just crashes.

Just wanted to give you a heads up. Looks great from the iTunes images. [import]uid: 123298 topic_id: 27220 reply_id: 110561[/import]

Hi and thanks for reporting this. I did not have chance to test it on anything else then the iPhone 4. I wonder if Corona supports the iPod touch? Also build I did was for iPhone, would such a build work for iPod touch as well or do I need to du universal build for the game to work on iPod touch as well?

Thanks for wanting to check it out, I hope I can fix it for iPod :slight_smile: [import]uid: 13099 topic_id: 27220 reply_id: 110594[/import]

Hey, just say your tweet :wink:

A build for iPhone will work on an iPod touch just fine. What version of Xcode were you using, what version of Corona and what iOS is your iPhone4 running currently? [import]uid: 52491 topic_id: 27220 reply_id: 110615[/import]

hi peach, will have to get back to you on this, currently at work and don’t have all the details right now :slight_smile: [import]uid: 13099 topic_id: 27220 reply_id: 110618[/import]

No worries, I’ll be off for the night shortly anyway - it’s 7pm here in Sydney. Take your time and I’ll check in here again tomorrow :slight_smile: [import]uid: 52491 topic_id: 27220 reply_id: 110623[/import]

Hey Nermion,

I ran the game while connected to xCode and it kept spitting out a low memory warnings.

So now, sometimes I can get to it. I see this girl and it has buttons on the side and you can give her different clothes and I could only change a few before it just crashes again and it takes me to the iPods menu screen.

So the build should work just fine for iPhone and iPod. Maybe your images are too big? [import]uid: 123298 topic_id: 27220 reply_id: 110661[/import]

Tried to run it on my iPad, it always crashes when i tap the Eye (3rd from top), and 5th icon from top also crashes a lot.

Seems to be a random thing all other icons crash the app every now and then…

[import]uid: 50459 topic_id: 27220 reply_id: 110663[/import]

Hi guys and thanks for extra details. Images are designed for iPhone 4 resolution, so they should not be too big or eat to much memory. Wonder why I did not get any chrashes when I tested it.

I’m using storyboard for this, wonder if that has anything to do with it.

@rmbsoft, probably wont be compatible with iPad since for this first release I built just for iPhone. Wonder if that really plays any roll for running it on iPad? What is actually differeny in universal release that Corona offers for iOS? [import]uid: 13099 topic_id: 27220 reply_id: 110664[/import]

btw Axie Studios how do I run the game while connected to xCode? I’d like to try that and see the warnings my self. [import]uid: 13099 topic_id: 27220 reply_id: 110665[/import]

iPhone apps should run fine on iPad.

Just tested it on my iPhone 4, and it seems to run fine.

If you start XCode, select Window menu -> Organizer.

Then Pick the iPhone you have connected, and click Console

[import]uid: 50459 topic_id: 27220 reply_id: 110666[/import]

Corona build: 825
xCode: 4.3.1 (4E1019)
iPhone: 5.1
I’ve collectgarbage to check the memory:

local showMem = function()  
 memDisplay.text = collectgarbage("count")/1000 .. "MB"  
 memDisplay.x = display.contentWidth \* 0.5  
end  
memTimer = timer.performWithDelay( 100, showMem, 0 )  

what gets printed is: values between 0.2 and 0.5

I’ve also checked the console output and noticed lowmemory warning. How much memory do we have to play with?

Actually managed to crash the app now, it seems to be low memory. I’ll have to look into this.
[import]uid: 13099 topic_id: 27220 reply_id: 110749[/import]

What about texture memory? Try adding this to your showMem function.

[lua] local textMem = system.getInfo( “textureMemoryUsed” ) / 1000000
print( "TexMem: " … textMem )[/lua]

And source:
http://developer.anscamobile.com/forum/2011/12/28/max-texture-memory [import]uid: 123298 topic_id: 27220 reply_id: 110751[/import]

I can’t imagine an app like that has memory problems, unless you don’t clean things up.

If XCode Organizer complains about memory warning, take note that it does this lots of times, combined with memory warnings about 3 or 4 other programs.

[import]uid: 50459 topic_id: 27220 reply_id: 110753[/import]

@Axie Studios

thanks for that one, I was foolish enough to only use collectgarbage function, was not really aware of textureMemoryUsed. I see now thats its over the top. Will have to clean some things up.

Currently I read in the textures in the array as the program starts and circle through them. For the cloths textures I do the same but instead of loading them at the start to shorten start times I decided to load them as they are called to display.

I put them in array so I dont have to load them each time. So when you cycle through the cloths and color variations of cloths, texture memory starts growing as files are read in.

Seems the solution will be to clean the previous image and replace it with one that is needed called for display. When I do this then probably application will be much more stable.

And also what is difference between builds for:
iPhone + iPad (universal)
iPHone Only
iPad Only

I did iPhone only build? Should I go with universal, what do the rest of you use? [import]uid: 13099 topic_id: 27220 reply_id: 110758[/import]

by the way is this correct:

local textMem = system.getInfo( “textureMemoryUsed” ) / 1000000

I’m getting 151 MB texture memory at the start. Shouldn’t this crash directly on all devices? Can’t really belive its that much. Perhaps as the png images get loaded into the memory an image that is 30 kb on the disk gets much bigger in the memory? Although my png images are not compressed as far as I know.

All images together that I use dont take more then 1.6 MB on the disk [import]uid: 13099 topic_id: 27220 reply_id: 110759[/import]

Definitely not the best guy to try to explain this. But I remember reading somewhere that image files will generally be bigger in memory when being rendered than what they are on disk.

Why? Or how? I don’t know. But I’ve noticed it too in my game. A simple png that’s only a 120KB on disk takes up like 4MB of texture memory when being on screen.

Also, your app works better if I leave my iPod off for a while. Run your app and I can cycle through various things but it eventually crashes after a short while.

Good luck with fixing it. I’m a noobie programmer, just wanted to let you know about the crash before you get bad reviews. [import]uid: 123298 topic_id: 27220 reply_id: 110760[/import]

thanks alot for that. I’ll do what I can to fix it, I managed to crash it on my iPhone4 as well now. Will have to do some rewritting it seems :slight_smile: [import]uid: 13099 topic_id: 27220 reply_id: 110764[/import]

Hey Nermion,

You wanted me to check in here but it seems as though you already know what needs to be done.

RE texture memory, 150mb wont necessarily crash on device - although I suspect on a 3G it would, maybe also a 3GS.

Let me know how your rewriting/editing is coming along.

Peach :slight_smile: [import]uid: 52491 topic_id: 27220 reply_id: 110940[/import]