• Our software update is now concluded. You will need to reset your password to log in. In order to do this, you will have to click "Log in" in the top right corner and then "Forgot your password?".
  • 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
11
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