Guide: how to decode the Pokémon GO GAME_MASTER file

Pokemon GO APK

Trainers,

it’s time to share some APK and game mining knowledge with the community. Here’s the first installment in our upcoming “APK Mining” series, explaining the following:

  1. What is the GAME_MASTER file?
  2. How to download the GAME_MASTER file from your Android phone
  3. How to decode the file and browse it’s contents

For this guide you’ll need the following:

  • a Android phone with the following apps
    • Pokémon GO updated to latest version and opened at least once
    • a Android File explorer
  • GO Hub’s GAME MASTER Decoder utility, which can be downloaded on GitHub, it’s public and open source
  • Basic knowledge of using a computer

Let’s get started! 🙂

What is the GAME_MASTER file?

In short, the GM file is a configuration file that Pokémon GO downloads when it’s started. It’s a file that defines a huge amount of the game: moves, DPS values, costs, requirements, rewards, etc… It’s a very important file and a majority of Pokémon GO websites use it to create accurate Tier lists, move sets, etc.

Game Master is downloaded from Niantic’s servers once and saved on your local Android device, as it’s a rather big file. To reduce the file size, Niantic sends the file using protocol buffers, a technology created by Google. You can think of proto buffers like ZIP for network traffic.

We’ve devised a utility that decodes (or unzips) the GAME_MASTER file into a human readable format and stores it in your clipboard.

2. How to download the GAME_MASTER file from your Android phone?

There is a number of different ways to retrieve this file, from connecting the phone to your PC to mailing the files to yourself. We usually use the later option, as it’s often more convenient and equally fast.

  1. First, you need to download any Android file explorer from the Google Play Store.
  2. After downloading the File Explorer, open it and navigate the following folder structure in the “internal/emulated storage” view:
    1. Android 
    2. data
    3. com.nianticlabs.pokemongo
    4. files
    5. remote_config_cache
  3. Select the GAME_MASTER file and send it to yourself using e-mail, Whatsapp, Google Drive or anything else you prefer.
  4. Download the file on your PC and proceed to Step 3.

3. How to decode the GAME_MASTER file?

In the past, in order to decode the GAME_MASTER you needed to know a number of advanced computer skills, including writing Command line scripts. In order to help the community, we created a small utility that does everything automatically for you.

We call it the Pogo Game Master Decoder! 🙂 Yeah, it’s a long name, but it’s a utility tool, so who cares. Let’s decode, shall we:

Here’s what you have to do:

The Preparation

  • Download the Decoder from Github – press the Clone or download button and select “Download ZIP”
  • Extract the ZIP file in a location of your choice.
  • Open the go-hub-game-master-decompiler folder and observe the structure of the folder:

The Decoding

  1. Open the Command Prompt in this folder:
    1. Hold Shift and Right Click in the empty folder space
    2. Select Open command window here
  2. Put the GAME_MASTER file you downloaded in Step 2. into the  game-master-files  folder. Don’t mess with dependencies or the gamemaster-decompile.bat if you’re not sure you know what you’re doing.
  3. Decode the file using the following command, replace the NAME_OF_YOUR_GAME_MASTER with the actual name of the file you downloaded from your phone. No path is needed, just the filename:
    gamemaster-decompile.bat NAME_OF_YOUR_GAME_MASTER
  4. The decoded GAME_MASTER is now in your clipboard, paste it in a text editor of your choice.
  5. Enjoy! 🙂

Example

There is no need to write the whole path to the GAME_MASTER file, just it’s name. Here’s a more concrete example:

gamemaster-decompile.bat 000001597FF747A8_GAME_MASTER

FAQ and Stuff

  • is this hacking or illegal?
    • No. Is opening a ZIP file illegal? Or transcoding a MP3 you bought to WAV illegal? Nope.
  • Is there anything malicious in the tool?
    • No. It’s a batch script and a lot hard has been done with those in the past, open it up and read if you are suspicious.
  • Is this guide available elsewhere?
    • Yes, on the SilphRoad. It’s a bit different there and it has no ads.
  • Can you make this for Linux/MacOS?
    • I’m working. Maybe on the weekend. Probably on a weekend.