Skip to content

Documentation versions

BGIN conversion, separate JSON, and new files ​

Use this page to create a separate text .json file or a new BGIN file. For opening and ordinary editing, use the main editor directly.

Get JSON from BGIN ​

JSON is a text description of screens, objects, and their properties. It can be useful for exchanging changes or passing the interface structure to other tools.

  1. Click Binary GIN in the vertical bar on the left of VS Code.
  2. Select BGIN → JSON.
  3. Under Source file → Choose…, select the original .bgin file.
  4. Under Output file → Save as…, choose a name for the new .json file.
  5. Click Convert, then Open result.

To get BGIN back, select JSON → BGIN, choose the input JSON and a new .bgin output, then click Convert.

Save your changes with Ctrl+S first: conversion reads files from disk. Input and output must be different files. Before replacing an existing result, the editor asks for confirmation and keeps its old contents in a neighboring .bak file. If the output is open with unsaved changes, save or close it first.

Conversion uses the same bundled BGIN worker as the editor. It does not need images or fonts.

Create an empty BGIN file ​

In VS Code, press Ctrl+Shift+P, find BGIN: New File, press Enter, and choose the new file's name and folder, then its BGIN format mode. You can also click Create empty BGIN in the Binary GIN sidebar.

On Windows, right-click empty space in a normal folder → New → Binary GIN. The extension adds this entry when running locally in VS Code. If it is missing, open the Binary GIN sidebar, click Add BGIN to the New menu, and reopen the folder's context menu.

The file starts empty. Open it in the editor, give it a document name, and create its first screen. Empty BGIN files may be kept: VS Code shows a warning. Their JSON is {"screens": []} without name.

Before uninstalling, click Remove BGIN from the New menu if you want to remove the Explorer entry. Administrator rights are unnecessary. This creation feature works locally on Windows, rather than through SSH, WSL, or a remote container.

Older file compatibility ​

The file variant is detected automatically; you do not need to choose a game version in Resources. Reading and saving were checked on all nine supplied June 2013 files, including widgets.bgin and sprites.bgin.

If the exported JSON includes "format": "legacy", keep that field: it tells the editor to save in the original older format. Keep unknown type and property names too. Reading and writing checks do not mean the preview exactly matches the older game, or that every other release is supported.

Convert BGIN to another format ​

  1. Select BGIN → BGIN in the sidebar.
  2. Choose a saved input and a separate output file.
  3. Select ~0.0.2, ~1.6.0, ~3.7.0 or ~5.8.0 in Target BGIN format.
  4. Click Convert. Data that cannot be represented without loss cause an error; no result replaces an existing destination.

Keep source format retains the original mode. BGIN → JSON and JSON → BGIN remain available; portable JSON carries its format with its data. The converter reads the saved file, so save the desired document edits first. Normal saving does not require changing formats.

For example, 5.8.0 additional property values cannot be silently discarded to produce 1.6.0. Unknown names in supported records are preserved as #1234ABCD, additional values as value with variants, and color channels as color_channels. Do not replace them with invented names.

Mode numbers represent wire formats around those A8 releases. Successful rebuilding does not establish compatibility with the target game's code. Texture conversion is separate.