This guide will help you get up and running with Corona for macOS.
Before proceeding, ensure that your system meets the core requirements to install Corona.
There are two ways to stay current with releases/builds of Corona:
In order to use Corona, you must be connected to the Internet and perform a simple
The first time you launch, you will be presented with a
If you've already registered for a Corona account, simply enter your account
Upon successful login, you will receive a confirmation dialog. You're ready to get started!
Installing Corona lets you create and test apps locally on your Mac. If you intend to build apps for testing on Android devices, you will need to install the
.dmgand run the installer.
You'll need a text editor or IDE to write code for your Corona projects. If you don't already have a favorite text editor, the following options are recommended:
|Xcode||Corona Plugin for Xcode|
|Visual Studio Code||Corona Tools|
|Sublime Text||Corona Editor|
The Corona development environment consists of two aspects: the
The Corona Simulator is a visual representation and test environment for your app. What you see in the Simulator is generally what your app will look like — and how it will function — when deployed to an actual device. The Corona Simulator is an essential tool because it allows you to view changes to your code instantly in an active, responsive environment that closely mimics the device.
The Corona Simulator Console is where you can view diagnostic messages about what's happening in your program.
The Corona Simulator for macOS features the following basic menu items:
The standard macOS application menu provides access to the Simulator Preferences. It also lets you manually open/run Corona Live Server for doing Live Builds on actual devices.
The File menu is where projects (applications) are created or opened. This is also where you build your apps for distribution or testing on devices.
The Hardware menu is used to simulate physical device actions such as rotating the screen.
The Window menu lets you open the Welcome Window which provides quick access to recent projects, Corona developer resources, and more. This menu also lets you access the Corona Simulator Console (Console). Finally, this menu includes options to manipulate the Simulator window or change the skin
If you're new to Corona, the most fun way to learn is to create a simple game. Don't worry if you've never created a mobile app or programmed before — the chapters in the guide will walk you through the entire process from start to finish!
To start a particular app in the Corona Simulator without double-clicking it, use a command like this:
"/Applications/Corona/Corona Simulator.app/Contents/MacOS/Corona Simulator" ~/CoronaApps/MyApp
If the specified directory doesn't contain a
main.lua file, an error is displayed. Optionally
-project can be specified (note that this suppresses any error messages if the directory is invalid).
If you don't want the Simulator Console window to automatically appear use the
"/Applications/Corona/Corona Simulator.app/Contents/MacOS/Corona Simulator" -no-console YES
Output from the Simulator will appear on standard output.
If you never want the Simulator to automatically start a console window, but for some reason cannot use the command line, you can run the following command in a Terminal window:
defaults write com.coronalabs.Corona_Simulator no-console -bool yes
Use this command to turn the Simulator Console back on again:
defaults delete com.coronalabs.Corona_Simulator no-console
One additional flag is allowed
-debug YES which allows an IDE to connect a debugger to the Simulator session. Specify it before the directory/file argument.