TOUR
PRICING
HELP
Stencylpedia
Blocks Guide
Sample Games
Developer Center
FORUMS
CHAT
#MADEINSTENCYL
EDUCATION
SIGN IN
×
Welcome back!
Username or E-mail
Password
(
Forgot?
)
C
OMMUNITY
Home
Issue Tracker
Inbox [0]
New Posts
New Replies
Search
Stencyl Community
→
Stencyl
→
Ask a Question
→
How to check if the device is connected to the internet? (Android ,iOS)
Pages:
1
How to check if the device is connected to the internet? (Android ,iOS)
popugames
Posts: 54
January 18, 2015, 06:18:04 am
I have a game that contains ads and i want to check every 30 seconds if the device is connected to the Internet
mdotedot
Posts: 1654
January 18, 2015, 06:39:35 am
Hi Popugames,
You can use blocks that are in Stencyl to connect to a website-URL and set a isConnected=False outside of the visit block and inside set isConnected=true.
http://www.stencyl.com/help/viewArticle/123
Hope this helps.
Best regards from
M.E.
Proud member of the League of Idiotic Stencylers! Doing things in Stencyl that probably shouldn't be done.
popugames
Posts: 54
January 18, 2015, 07:07:33 am
Can you give me an example ?
Thank you.
« Last Edit: January 18, 2015, 07:40:25 am by popugames »
TEDDD
Posts: 4
August 10, 2024, 05:36:25 am
I checked what mdotedot wrote.
It works for me.
I did not expect that such an arrangement of blocks would be correct and would work. But it works:)
The first screen on top shows the detection of no internet connection.
The second screen on bottom, return to game, when the player is connected to the Internet.
Link to URL is randomly chosen by me
mg][/img]
Pages:
1