Jump to content

[TOPIC: topicViewTemplate]
[GLOBAL: userSmallPhoto]
Photo

managed to get out first corona game
Started by maxnb Jun 06 2012 05:59 AM

18 replies to this topic
[TOPIC CONTROLS]
This topic has been archived. This means that you cannot reply to this topic.
[/TOPIC CONTROLS]
[modOptionsDropdown]
[/modOptionsDropdown]
[reputationFilter]
[TOPIC: post.html]
#1

maxnb

[GLOBAL: userInfoPane.html]
maxnb
  • Enthusiast

  • 66 posts
  • Corona SDK

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.
uid: 13099 topic_id: 27220 reply_id: 327220


[TOPIC: post.html]
#2

Axie Studios

[GLOBAL: userInfoPane.html]
Axie Studios
  • Enthusiast

  • 61 posts
  • Corona SDK

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.
uid: 123298 topic_id: 27220 reply_id: 110561


[TOPIC: post.html]
#3

maxnb

[GLOBAL: userInfoPane.html]
maxnb
  • Enthusiast

  • 66 posts
  • Corona SDK

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 :)
uid: 13099 topic_id: 27220 reply_id: 110594


[TOPIC: post.html]
#4

peach pellen

[GLOBAL: userInfoPane.html]
peach pellen
  • Corona Geek

  • 8,866 posts
  • Alumni

Hey, just say your tweet ;)

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?
uid: 52491 topic_id: 27220 reply_id: 110615


[TOPIC: post.html]
#5

maxnb

[GLOBAL: userInfoPane.html]
maxnb
  • Enthusiast

  • 66 posts
  • Corona SDK

hi peach, will have to get back to you on this, currently at work and don't have all the details right now :)
uid: 13099 topic_id: 27220 reply_id: 110618


[TOPIC: post.html]
#6

peach pellen

[GLOBAL: userInfoPane.html]
peach pellen
  • Corona Geek

  • 8,866 posts
  • Alumni

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 :)
uid: 52491 topic_id: 27220 reply_id: 110623


[TOPIC: post.html]
#7

Axie Studios

[GLOBAL: userInfoPane.html]
Axie Studios
  • Enthusiast

  • 61 posts
  • Corona SDK

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?
uid: 123298 topic_id: 27220 reply_id: 110661


[TOPIC: post.html]
#8

rmbsoft

[GLOBAL: userInfoPane.html]
rmbsoft
  • Contributor

  • 444 posts
  • Corona SDK

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...

uid: 50459 topic_id: 27220 reply_id: 110663


[TOPIC: post.html]
#9

maxnb

[GLOBAL: userInfoPane.html]
maxnb
  • Enthusiast

  • 66 posts
  • Corona SDK

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?
uid: 13099 topic_id: 27220 reply_id: 110664


[TOPIC: post.html]
#10

maxnb

[GLOBAL: userInfoPane.html]
maxnb
  • Enthusiast

  • 66 posts
  • Corona SDK

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.
uid: 13099 topic_id: 27220 reply_id: 110665


[TOPIC: post.html]
#11

rmbsoft

[GLOBAL: userInfoPane.html]
rmbsoft
  • Contributor

  • 444 posts
  • Corona SDK

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

uid: 50459 topic_id: 27220 reply_id: 110666


[TOPIC: post.html]
#12

maxnb

[GLOBAL: userInfoPane.html]
maxnb
  • Enthusiast

  • 66 posts
  • Corona SDK

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.
uid: 13099 topic_id: 27220 reply_id: 110749


[TOPIC: post.html]
#13

Axie Studios

[GLOBAL: userInfoPane.html]
Axie Studios
  • Enthusiast

  • 61 posts
  • Corona SDK

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

local textMem = system.getInfo( "textureMemoryUsed" ) / 1000000    print( "TexMem:   " .. textMem )


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


[TOPIC: post.html]
#14

rmbsoft

[GLOBAL: userInfoPane.html]
rmbsoft
  • Contributor

  • 444 posts
  • Corona SDK

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.

uid: 50459 topic_id: 27220 reply_id: 110753


[TOPIC: post.html]
#15

maxnb

[GLOBAL: userInfoPane.html]
maxnb
  • Enthusiast

  • 66 posts
  • Corona SDK

@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?
uid: 13099 topic_id: 27220 reply_id: 110758


[TOPIC: post.html]
#16

maxnb

[GLOBAL: userInfoPane.html]
maxnb
  • Enthusiast

  • 66 posts
  • Corona SDK

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
uid: 13099 topic_id: 27220 reply_id: 110759


[TOPIC: post.html]
#17

Axie Studios

[GLOBAL: userInfoPane.html]
Axie Studios
  • Enthusiast

  • 61 posts
  • Corona SDK

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.
uid: 123298 topic_id: 27220 reply_id: 110760


[TOPIC: post.html]
#18

maxnb

[GLOBAL: userInfoPane.html]
maxnb
  • Enthusiast

  • 66 posts
  • Corona SDK

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 :)
uid: 13099 topic_id: 27220 reply_id: 110764


[TOPIC: post.html]
#19

peach pellen

[GLOBAL: userInfoPane.html]
peach pellen
  • Corona Geek

  • 8,866 posts
  • Alumni

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 :)
uid: 52491 topic_id: 27220 reply_id: 110940



[topic_controls]
[/topic_controls]