From the Forum — Issue #97

From the Forum — Issue #97

From the ForumWelcome to the latest installment of From the Forum. In this series, guest blogger Alex Jackson highlights outstanding threads from the Corona Forum. The goal is to bring attention to the most captivating, interesting, and thought-provoking discussions taking place in our very own backyard.

Please visit the forum to join these conversations or start your own!


1. Be the boss when getting your textfields straight

Having Corona be so versatile can be a double-edged sword. It can do a lot of things very well, from incorporating third-party libraries to fast prototyping for pitch material. When you just need something simple to work, but have a unique design scheme, Corona always comes through.

Working with Enterprise-level app deployments is something that requires some serious pre-production to get right. In most cases, the nitty-gritty will be considered and worked out well in advance. To give you a leg up here, below is a link that gives away the twist, right in title! A good samaritan Corona developer shares their code for auto-capitalization in textfields with the class.

Take advantage of the good karma and get down to the original thread to tuck that snippet:

http://forums.coronalabs.com/topic/49398-textfield-auto-capitalization/

2. Set the baseline to soar

Hardware is progressing faster than ever. Even the lowest tier phones can handle mid-range games well without dropping frames. However, travel back a bit too far, and you’ll start finding phones that choke on something that a slab from 8 months ago would chug through with no problem.

This is strictly an Android-specific tip, but if you want to avoid bad reviews from users with devices that can’t run your app, or just ensure that your app can only be run on devices you are certain will be able to handle it, Corona has exposed the ability to set the minimum SDK your app. WARNING: This should only be modified by those who expressly understand exactly how this will affect their app.

Click through to the original post to see what is involved in taking this plunge.

https://forums.coronalabs.com/topic/57824-minimum-sdk-version/

3. Detect tablet devices via DPI

Getting to the bottom of which device your app is running on is fraught with peril. It can be as simple as detecting OS and acting accordingly, or you would need to do some serious code-jitsu to identify whether you’re dealing with an iPhone 8 or an iPad Pro. Device size can have a huge impact on the way you render assets, and as such, knowing the exact device you’re dealing with is a huge piece of the puzzle.

Depending on your app’s genre and architecture, you might just be well-served to capture the DPI (Dots Per Inch). This is becoming more and more antiquated, as smaller devices pack more and more pixels into their screens. However, this method is still valid for some applications, so I wanted to make sure it was highlighted before it got sunsetted.

Head on over to the original post while the getting is good!

https://forums.coronalabs.com/topic/54902-best-way-to-determine-ipad-or-other-tablet/


About Alex

Alex Jackson is an indie developer and the founder of Panc Interactive, specializing in retro-style gaming. He has created several mobile applications, enjoys long walks on the beach, pixel art, and reading the Corona forums. Contact him by email or follow him on Twitter: @pancinteractive. Check out his new game Segreta on iOS, Android, Windows Phone and Amazon devices.

Brent Sorrentino
brent@coronalabs.com

Brent Sorrentino is a full-time Developer Evangelist and technical writer who assists others with game development, code, and in overcoming other challenges to help them bring their app dreams to life.

No Comments

Sorry, the comment form is closed at this time.