i created a game for android but when i play it after a little while it shows this message “/Users/jenkins/slaveroot/workspace/templates/label/android/subrepos/widget/widgetLibrary/widget_button.lua:680: attempt to preform arithmetic on field ‘x’ (a nil value)”
Can you post your code where you are creating your button? I’m assuming “Words Completed” is the button in question.
Also, I looked at the code for the widget library and that error is in the :setLabel() function which could be called when the button is created or later by actually calling :setLabel().
Please also post any code where you’re changing the label. Please use the blue <> button in the row with Bold & Italic to popup a window to paste your code into.
Since you’re on a Mac, are you having Corona install the build to your test device via a USB cable? If so, and you don’t close the dialog box that says when it’s done installing, then the Corona console log, should be displaying messages from the device’s console log. There is likely a longer stack trace that could provide more information as to what the problem is. You may have to use the “adb logcat” command (which may require you to install the adb tools) or you can use Android Studio to view the device’s log.
The error seems like it can only happen if you’re trying to set the label on a button that’s been removed.
Can you post your code where you are creating your button? I’m assuming “Words Completed” is the button in question.
Also, I looked at the code for the widget library and that error is in the :setLabel() function which could be called when the button is created or later by actually calling :setLabel().
Please also post any code where you’re changing the label. Please use the blue <> button in the row with Bold & Italic to popup a window to paste your code into.
Since you’re on a Mac, are you having Corona install the build to your test device via a USB cable? If so, and you don’t close the dialog box that says when it’s done installing, then the Corona console log, should be displaying messages from the device’s console log. There is likely a longer stack trace that could provide more information as to what the problem is. You may have to use the “adb logcat” command (which may require you to install the adb tools) or you can use Android Studio to view the device’s log.
The error seems like it can only happen if you’re trying to set the label on a button that’s been removed.