Search Unity

  1. We've closed the job boards. If you're looking for work, or looking to hire check out Unity Connect. You can see more information here.
    Dismiss Notice
  2. Unity 2017.3 has arrived! Read about it here.
    Dismiss Notice
  3. Want to see the most recent patch releases? Take a peek at the patch release page.
    Dismiss Notice

Online Check - Verify Internet reachability

Discussion in 'Assets and Asset Store' started by Stefan-Laubenberger, May 24, 2017.

  1. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    715
    Online Check

    Online Check
    is a simple, configurable tool to reliably check your connection to the Internet – in the editor as well as at runtime, where you need it, when you need it.

    Unity’s internal reachability check returns the type of Internet reachability possible on the current device.

    As mentioned in their documentation, this does not check for your actual connectivity – it only determines whether the device can, for example, connect to a hot spot. That’s not very helpful if it the actual route to the network is unavailable.

    Its main purpose is to gain a little bit more comfort by keeping track of your connection state, without consulting your browser or the OS display which both usually cause an unnecessary delay. This tool doesn’t check if you’re connected to a specific network. It checks if you have access to the Internet, which, for example, comes in handy when you’re on the road connected to a public WiFi.

    Features:
    Internet connectivity

    • Reliably check for Internet connectivity:
      • Run on Start: Run the check as soon as the scene loads
      • Manual Mode: Check whenever you need it
      • Endless Mode: Automatically check continuously between intervals
      • Fallback check: Keeps checking in case of connection loss
    • Freely configurable intervals
    • Maximum 8 KB of data downloaded per hour (at 10 checks per minute)
    • Specialized checks for each platform:
      • Windows / WSA (UWP)
      • MacOS / iOS
      • Linux / Android
      • Generic for all other platforms and devices

    Documentation & control
    • Test the checks in the editor!
    • Powerful API for maximum control!
    • Proxy manager for Internet connections!
    • Detailed demo scenes!
    • Comprehensive documentation and support!
    • Full C# source code in the PRO version!

    2.3.Compatibility
    • Supports all build platforms!
    • Works with Windows, Mac and Linux editors!
    • Compatible with Unity 5.3 – Unity 2018
    • PlayMaker actions!


    Some impressions:

    Screenshot_25-Jun-2017-23-11-48-2.png

    Screenshot_25-Jun-2017-23-12-22-0.png


    Video:




    AssetStore:
    PRO edition
    Standard edition

    Our other assets


    Demos:
    Windows
    Mac
    Linux
    Android


    Feel free to download and test it.
    Any constructive comments are very welcome!


    So long,
    Stefan
     
    Last edited: Jan 18, 2018 at 10:22 PM
  2. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    715
    We've created a basic tutorial video:

     
  3. davidosullivan

    davidosullivan

    Joined:
    Jun 9, 2015
    Posts:
    362
    Hi there, I just bought the pro version for learning processes mainly. Nice asset works really well :)

    I was hoping you could clarify something for me?

    What is the reason for the IntervalMin and Max values, is there some issue with polling at a regular interval or something?
     
  4. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    715
    Hi David

    Thank you for buying our asset!

    Those two values are the random range for the polling. The reason is that you don't wanna get banned by one of the verification sites - a random interval helps :)

    I hope this answers your question.


    So long,
    Stefan
     
  5. davidosullivan

    davidosullivan

    Joined:
    Jun 9, 2015
    Posts:
    362
    Thanks for the prompt response!

    Right ok that makes sense. And thats why you supply the fallback url? How much of an issue is that? Like how likely is it that you do get banned?
     
  6. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    715
    It's very unlikely to get any sorts of problems as long as you don't set the interval very low, e.g. all 0.5 seconds.
    This is why we limit the range to a minimum of 3 seconds. With the default settings, you will have an average of 7 seconds for a test. This should be accurate enough :)

    The fallback is only used if, for what ever reason, the main check fails.
     
  7. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    715
    We've just released version 1.4.0 to the store.
    Main changes:
    • Compile define symbol "CT_OC" added
    • id file added
    • Asset path in Editor removed, locate it automatically!
    • Editor scripts better organized


    Cheers
    Stefan
     
  8. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    715
    The new version is at the store!
     
  9. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    715
    We've just released version 1.4.1 to the store.
    Main changes: new check algorithm and small fixes to the code.

    We also created new versions of our downloadable demos.
     
  10. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    715
    The new version is at the store.
     
  11. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    715
    We've just released version 1.4.2.
    Changes:
    • "Dont Destroy" added to OnlineCheck
    • Support for pre Unity 5.3 dropped
     
  12. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    715
    The new version is at the store!
     
  13. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    715
    We've just released version 1.4.3 to the store.
    Some changes:
    • Asset moved to "Plugins"
    • NYCheck added
    • Code cleanup

    Have a nice Christmas!


    Cheers
    Stefan
     
  14. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    715
    The new version is at the store!
     
  15. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    715
    We've just released version 1.5.0.
    It contains minor improvements.
     
  16. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    715
    The new version is at the store!
     
  17. Weezel

    Weezel

    Joined:
    Apr 20, 2013
    Posts:
    24
    Hi, I have a couple of questions. Does this asset work on WebGL? Can it get the network SSID (also on WebGL)?
     
  18. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    715
    Hi

    1. Yes it works with WebGL.
    2. No, it can't get the SSID.

    Cheers
    Stefan
     
  19. Weezel

    Weezel

    Joined:
    Apr 20, 2013
    Posts:
    24
    Thanks for the quick response!
     
    Stefan-Laubenberger likes this.
  20. pangsscn

    pangsscn

    Joined:
    Sep 11, 2017
    Posts:
    5
    Hi Stefan,
    I have bought the pro version, Can I check my socket server's status? and How to do?
    I just want to know the internet is connect and my socket server's status.
     
  21. Stefan-Laubenberger

    Stefan-Laubenberger

    Joined:
    May 25, 2014
    Posts:
    715
    Hi

    OC "only" tests if your app can connect to the Internet.
    It isn't intended to check if a specific server is alive - this is planned for an upcoming asset ;)

    However, if you wanna check the connection status of a socket, you could do it like this:
    Code (CSharp):
    1.  
    2. public bool isSocketConnected(Socket s)
    3. {
    4.    return !(s.Poll(1000, SelectMode.SelectRead) && s.Available == 0);
    5. }
    6.  
    I hope this is useful for you!


    Cheers
    Stefan