Hi,
My game have interstitial ads that is shown in a specific moment of the game. But if the device is not connected to the internet the interstitial ads won't show. I would like to make sure that the device is connected to the internet, so it can load and show the interstitial ads. When there is no internet connection the game hangs trying to show the interstital. Is there a way to check if the device is connected? And if the device its not connected, is there a way to skip the interstitital and proceed with the game, without hanging? Thanks!
Hi, My game have interstitial ads that is shown in a specific moment of the game. But if the device is not connected to the internet the interstitial ads won't show. I would like to make sure that the device is connected to the internet, so it can load and show the interstitial ads. When there is no internet connection the game hangs trying to show the interstital. Is there a way to check if the device is connected? And if the device its not connected, is there a way to skip the interstitital and proceed with the game, without hanging? Thanks!
As covered in the Browser section of the manual:
If you have the Browser object in your project you can use the condition
Is online True if the browser currently has an active connection to the internet. [/code:d74auqgi] You could also try the expression [code:d74auqgi]ConnectionType The type of connection technology in use if it is known. This can be "bluetooth", "cellular", "ethernet", "wifi", "wimax", "other", "unknown" or "none" (indicating offline mode).[/code:d74auqgi]
Develop games in your browser. Powerful, performant & highly capable.
Alydus,
Thanks and sorry, it is for mobile phones, tablets and desktop.
zenox98,
Thank you too. How can i use this ConnectionType, i can't see this on browser actions or conditions?
I really appreciated your help. I will use a browser event.