Where does the magazine print when I use print ("") in the Corona Engine?

I used the print("Helloworld") function in the code where the output is printed?

+4
source share
2 answers

Much depends on how you started Corona, and if you are on a Mac or PC, or if you are looking for this information while working in the Xcode simulator or on the device.

For Macs, it is best to run the Corona SDK using the "corona-terminal" application in the Applications / CoronaSDK folder. This will launch the Terminal application, which in turn will launch the Corona SDK. Your errors, warnings and print statements will be displayed in the terminal window that starts. There are several IDE type editors that can run the Corona SDK for you, in which case they can capture output and display it in the IDE.

On the PC, the Corona SDK will launch the cmd shell screen for you. Print messages are displayed there. A.

When using the Xcode simulator (and not the Corona SDK simulator), you will find the result in the console application. Using a spotlight (a magnifying glass in the upper right corner of your mac), enter โ€œConsoleโ€ and launch the application.

If you installed the application on an Apple device, you can use Xcode Organizer with your device tied to a Mac USB port, and there is a link in the left navigation bar called โ€œConsoleโ€ that allows you to see the log messages from the device.

On Android, you need to install "Android Debug Bridge", and from the terminal window you can enter the command:

  adb logcat 

with your Android device tied to your computerโ€™s USB port to view console log messages from your Android device. The Android device must be in "developer mode" for this to work.

+12
source

If you are using a Mac, follow these steps:

  • Open finder
  • Go to Applications> Corona SDK> Corona Terminal
  • After starting, click the "Simulator"
  • Go to the project folder and select "main.lua" (your project launch file).
  • Then it will open your program in the simulator and at the same time print the logs in the terminal.

If you are using a PC, simply double-click Corona and the terminal will automatically open.

+3
source

Source: https://habr.com/ru/post/1482518/


All Articles