Hi, I can’t understand why the alert popup doesn’t appear more than twice. It appear the first time, then when I press “Riprova” it appears again, but if I press “Riprova” for the second time it doesn’t appear anymore.
Here the code:
function connection() local status = network.getConnectionStatus() if status.isConnected then gameNetworkSetup() if detect == "classifica" then postScoreSubmit() gameNetwork.show("leaderboards") elseif detect == "trofei" then gameNetwork.show("achievements") end else connectionAlert = native.showAlert("Errore di connessione", "Non è stata rilevata alcuna connessione a Internet.", {"Annulla", "Riprova"}, fConnectionAlert) end end function fConnectionAlert(event) if "clicked" == event.action then local i = event.index if 1 == i then native.cancelAlert(connectionAlert) elseif 2 == i then connection() end end end