• Just a reminder that providing specifics on, sharing links to, or naming websites where ROMs can be accessed is against the rules. If your post has any of this information it will be removed.
  • Ever thought it'd be cool to have your art, writing, or challenge runs featured on PokéCommunity? Click here for info - we'd love to spotlight your work!
  • Our weekly protagonist poll is now up! Vote for your favorite Conquest protagonist in the poll by clicking here.
  • Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.

v19 Check for Update (Main Menu)

Zeak6464

Zeak #3205 - Discord
  • 1,101
    Posts
    12
    Years
    url = "https://someurl.com/version.txt"
    This checks where to look online for the version number

    GAME_VERSION
    this is located in your setting script
    Code:
     GAME_VERSION = '1.0.0'

    version.txt
    must contain the Game_Version example
    Code:
    1.0.0

    In UI_LOAD at def pbStartLoadScreen

    add in under cmd_quit = -1
    Code:
    cmd_update       = -1

    in the same def pbStartLoadScreen
    add in above commands[cmd_new_game = commands.length] = _INTL('New Game')

    Code:
    socket = HTTPLite.get("https://www.google.com")
          if !socket
            latest_ver = "Unknown"
          else
            url = "https://someurl.com/version.txt"
            latest_ver = pbDownloadToString(url)
          end
        
          vertext=_INTL("Game Version: {1}",Settings::GAME_VERSION)
          if latest_ver == "Unknown"
            vertext=_INTL("No internet detected")
          elsif Settings::GAME_VERSION != latest_ver
            vertext=_INTL("Update Available")
          end
        
        commands[cmd_update=commands.length]      = _INTL("{1}", vertext)
     
    Back
    Top