The problem appears to be essentially the JRE included with Solard2D/Corona SDK on silicon Macs.
There are two ways to fix this. The simplest is to install Rosetta and use the included JRE:
softwareupdate --install-rosetta
But there’s another solution: using a native jre for Silicon.
I looked for the same version used by the latest version of Solar2D, 17.0.6.
I downloaded the tar.gz to avoid system installations and cluttering the environment. I also used a symbolic link to keep the original corona package as clean as possible.
Basically, you can follow these steps from the command line. If you don’t have wget, you can use curl.
# let’s move it to a neutral directory
cd tmp
# download the tar.gz with wget
wget “https://github.com/adoptium/temurin17-binaries/releases/download/jdk-17.0.6%2B10/OpenJDK17U-jdk_aarch64_mac_hotspot_17.0.6_10.tar.gz”
# or with curl (-o for the file name, -L to follow redirects)
# curl -o OpenJDK17U-jdk_aarch64_mac_hotspot_17.0.6_10.tar.gz -L https://github.com/adoptium/temurin17-binaries/releases/download/jdk-17.0.6%2B10/OpenJDK17U-jdk_aarch64_mac_hotspot_17.0.6_10.tar.gz
# let’s create a folder in our home
mkdir -p ~/jdks
# let’s unzip the file
tar -xzf OpenJDK17U-jdk_aarch64_mac_hotspot_17.0.6_10.tar.gz -C ~/jdks
# let’s remove the archive
rm OpenJDK17U-jdk_aarch64_mac_hotspot_17.0.6_10.tar.gz
# let’s give it a more compact name
mv ~/jdks/jdk-17.0.6+10 ~/jdks/jdk-17.0.6
# Let’s rename the Solar2D jre
mv /Applications/Corona-3729/Corona\ Simulator.app/Contents/jre/jdk /Applications/Corona-3729/Corona\ Simulator.app/Contents/jre/jdk_old
# let’s point the directory to the silicon JRE
ln -s ~/jdks/jdk-17.0.6 /Applications/Corona-3729/Corona\ Simulator.app/Contents/jre/jdk
voilà.