May 232012
 

We recently started on a fairly large mobile app. Our previous apps have been written using Ansca’s CoronaSDK (http://www.anscamobile.com/). For the most part Corona has met our needs, however recently we have had a lot of issues with stability. These issues have caused some negative reviews in the iTunes App Store. Also, there are some other features we would like to take advantage of that Corona does not currently support and may never support. There is no clear timeline for upcoming features.

Stability Issues
Some of the stability issues in the past few months include:

  • Full Screen Inneractive Ads lock up the app. This was recently fixed, but I reported this back in January. It is now May. Given that Ansca and Inneractive have both pushed using the Inneractive ad system since it was first introduced, you would have thought that this would have been a high priority bug to fix and not one that took 5 months to address.
  • Nook Color crashed at start up. Fixed in Build 819, but all that was required was a simple regression test to know it was broken. Read more here.

Additional Features Needed
These items really aren’t anything to complain about since there are plenty of apps that have no need for the same things we do, but for us these are issues worth noting:

  • LUA modules cannot be placed in sub folders
  • Texture memory is not optimized
  • Unable to extend the Corona API

LUA modules cannot be placed in sub folders
One of the key elements in our upcoming app is that it is essentially a collection of games in a single app. This means a LOT of assets, and a lot of different code modules to handle each games logic. Currently Corona does not support putting lua files in sub folders for all target devices. I’ve had success getting that to work on iOS devices, but it fails miserably on Android devices.

Texture memory is not optimized
Another issue with Corona has to do with texture memory. Corona uses one of two functions to load a texture:


-- Assume the image is 1024x768 and we want to display it
-- on a 480x320 device

local image1 = display.newImage( "image1.png" )
image1.scaleX = 480/1024
image1.scaleY = 320/768

local image1 = display.newImage( "image1.png", 480, 320 )
-- no need to scale since that is what the two params did,
-- BUT it still takes the same memory as the first call

In both cases the memory that the system will use for the texture is 1024x768xdepth. Ideally, we would want the second version to only take up 480x320xdepth bytes. This would mean we could have ONE high resolution image and use it on all platforms. Yes, we can do that now, but on the low resolution devices it will take the same amount of in app memory as the high resolution devices. This means that we have to create separate versions of the art for each resolution we want to support in order for the game to fit into memory. I really do not understand why they implemented it this way when all that had to be done was load the image into memory, resize it in code, then use the resized image for the actual texture display memory.

So the way we handle it is to create low, medium and high resolution versions of most images and put those in folders named “low”, “medium” and “high”; and a few we just have one version and dump those in a “common” folder.

Corona has something similar with their dynamic content scaling solution. However, this doesn’t address the texture memory issue, nor the bloat that comes from having to have multiple versions of key images.

With a proper load function we would be able to just have a common image and use it for whatever resolution we want by dynamically scaling the width and height for the actual device display resolution. Nice and memory efficient and we don’t double our APK or IPA size with copies of assets at different resolutions.

Unable to extend the Corona API
This issue along with the stability problems are probably the biggest reasons to consider moving away from Corona. Because Corona is not open source, we have to way to add features using platform API’s. I realize that is probably not the typical use of Corona as it was really targeted for Game Designers and not Game Programmers.

It would be fine if the community could request a feature and have a reasonable expectation that Ansca would add it to their API, but something as simple as pixel access to textures is still not in Corona and people have requested it for over a year.

Part 2 coming soon

P.S.: Like this article?! Want to support?! Be free to donate with bitcoins! 19r39vr2zs14aHW6DMNtPjmRga9xERQTTP

 Posted by at 2:28 am
May 152012
 

I’ve been using Ansca’s Corona SDK for almost a year. I made the decision to use Corona because it allowed rapid development via Lua, and the SDK met almost all of my needs at the time I chose it.

I’ve made numerous contributions to the Corona Community, and even donated my time in solving other people’s issues. Because of my strong belief in the SDK I signed up to be a Corona Ambassador.

Over the past few months something has become painfully obvious to me and a number of other Corona developers. Corona just doesn’t have the support it should. The software development process is flawed and because of this they keep pushing out Daily Builds that are buggy and cause any of a number of issues for developers.

Just go into the Corona Forums and you will see what I mean. One common thread goes something like this:

“I’ve had lots of problems with Corona. I write up the issues on the Forums and hear nothing back from Ansca. If I do get support it’s almost always from another developer who has gone down the same road and run into the same issue. It seems like the community is figuring out solutions to more of the problems than Ansca is. What gives?”

The above isn’t an exact quote, but it is a compilation of a number of complaints developers have had. As a Corona Ambassador I try and jump in and solve the issue whenever possible, but that doesn’t work when it is a fundamental issue with Corona.

For instance, recently I submitted 3 apps to the Barnes and Noble Nook store. All 3 passed for Nook Tablet, but all 3 were rejected for the Nook Color. I searched high and low for differences between the platforms, but other than the Color having half the memory of the Tablet and some differences in the video card and clock speed, they are supposed to be identical. Our apps only use 80MB of memory so it shouldn’t have been due to memory. After spending days trying to figure out what might be happening, I contacted Ansca and asked them about any issues they might know regarding the Nook Color. This was Ansca’s response:

yes we are aware of this issue. We think it’s due to some rendering changes a week ago on Android

On the one hand, I was glad to hear it was a known issue. However, why didn’t they post something in the Corona Developer Forum letting people know to hold off on Nook Color submissions? I mean really, if you know there is an issue, then why keep it a secret?

One typical response goes something like this: “the daily builds are NOT stable and we make that very clear”. Sure, that is very true. However, since the stable builds only come out a few times a year, and because there are KNOWN crash bugs that have been fixed ONLY in the Daily Builds what is a developer to do? What until the next stable build? That could be weeks or months away and we have no idea when it will occur.

Here’s another example of the instability of Corona. We recently submitted 3 apps to iTunes. All 3 were accepted and are now available in the iTunes store. Almost immediately we started getting complaints in our reviews from users that the game wouldn’t load. These negative comments materially affect our business. Having people make comments that our games are crap or that our company sucks is NOT good for business.

So we posted an update to our description asking people who experience the problems to let us know what device and OS they are using. The response so far is iPhone 4, OS 5.1.1. Of course we had tested on this device, but we believe the user is having an issue so we do some more testing. Our app runs fine for us. If you know much about software development then you can probably guess that the issue is almost certainly an uninitialized variable. That would cause it to work fine sometimes and not other times.

Guess what? Any uninitialized variables have to be in the Corona SDK as it uses Lua for the developer coding and Lua sets all variables to “nil” unless you explicitly set them to some other value. That means that our code will run the same way from one run to another, unless you are past the load and into the game where random numbers get used. Since the app just gets a black screen at start-up for the user, it is clear this is not in our code, but something in Corona.

Ansca, PLEASE fix these issues. PLEASE stop with the Daily Unstable Builds. PLEASE put out regular stable builds every 2 weeks, every month, whatever period works for your team size.

I want to continue using Corona as it is a very nice solution when it works. However, if these issues aren’t resolved soon I will be forced to move to another SDK (and there are a number of them now).

P.S.: Like this article?! Want to support?! Be free to donate with bitcoins! 19r39vr2zs14aHW6DMNtPjmRga9xERQTTP

 Posted by at 5:32 pm