View Format: Multi-Page Single Page

JSON Workflow

Create Hundreds of Game Entries in Seconds Instead of Hours.

Export your database structure as JSON, generate content with any tool you like, and import it back into the forge wizards. This is how all four demo games were built.

The JSON Content Pipeline

Every forge in Simple Idle Forge can export its structure as JSON and import entries from JSON. This means you can create game content outside the Unity Editor — using spreadsheets, text editors, scripting tools, or any workflow that outputs JSON — and import it directly into your game databases. No manual data entry, no clicking through dozens of fields one at a time, no copy-paste errors.

This is not a minor convenience feature. It is the fastest way to build an idle game. Think about what goes into a typical incremental game: 10–20 resources, 15–30 generators each with multi-resource costs and production rates, 30–50 upgrades with prerequisites and effect configurations, multiple prestige layers with reset rules and permanent bonuses, and 30–50 achievements with conditions and rewards. That is hundreds of individual entries, each with multiple fields that need to be filled out correctly and consistently.

The JSON pipeline turns that from hours of manual work into a structured, repeatable process. You export your schema once to understand the format. You generate your entries in whatever environment you are most productive in — a spreadsheet, a text editor, a scripting language, or any external tool that can produce JSON. Then you import the result, validate it, and generate your database. Done.

All four demo games included with Simple Idle Forge were built this way. Simple Kingdom (45+ entries), Factory Tycoon (70+ entries), Survival Idle (80+ entries), and RPG Idle (95+ entries) — every resource, generator, upgrade, prestige layer, and achievement was created through the JSON pipeline and imported into the forge wizards. The JSON source files are included in the package so you can study the exact format that produced complete, playable idle games.

Three Export Formats

Each forge's Definitions step (Step 2) has export buttons for three formats. Each format serves a different purpose, and you will likely use all three at different points in your workflow.

Complete

Full JSON

Exports everything: your property definitions, all existing entries with every field filled in, all linked database codes, cost configurations, prerequisites, milestones, rewards, and every custom property value on every entry. This is the complete picture of your database in a single file.

Use Full JSON when you want a backup of your entire database, when you want to share your work with a team member, or when you want to see exactly what the import format looks like with real data. If you are unsure which format to use, start with Full JSON — it contains everything the other formats contain, plus your actual entries.

Template

Light JSON

Exports only your property definitions — the structure of your database without any actual entries. This tells external tools what fields are available, what types they expect, what enum values are valid, and how entries should be formatted, without including any of your existing game data.

Light JSON is the format you export first. It is your template. Hand it to whatever tool or workflow you use to generate content, and that tool knows exactly what fields to fill in, what values are acceptable, and how to structure the output so it imports cleanly. Think of it as the blueprint for your content factory.

Reference

Markdown

Exports a human-readable summary of your database structure — formatted as Markdown text that you can read, share, paste into a document, or include in your project's design documentation. It lists every property definition, every valid enum value, every linked database, and a plain-English description of what each field does.

Markdown export is useful for documentation, for sharing your database structure with designers or writers who do not use Unity, and for keeping a readable reference of your game's data architecture alongside your project files. It is not importable — it is purely for human consumption.

Recommended Workflow

Export Light JSON first as your template. Generate your entries using that template as a reference for field names and valid values. Import the result. Then export Full JSON as a backup of your completed database. Use Markdown whenever you need to share the structure with someone who does not have Unity open.

The Database Export Window

In addition to the per-forge export buttons in Step 2, Simple Idle Forge includes a standalone utility window for exporting generated databases. You will find it at Window → Living Failure → Simple Idle Forge → Export Database.

The Database Export Window works differently from the wizard export buttons. While the wizard buttons export from your wizard data (the entries you are still editing), the Database Export Window exports from your generated database — the final, compiled asset that your game reads at runtime. This is useful in several situations:

  • Backing up your work. After generating a database, export it as JSON so you have a portable copy of your final data that is not tied to Unity's asset format.
  • Sharing between projects. Export a database from one Unity project, carry the JSON file to another project, and import it into a fresh forge wizard there. Your entire database travels as a single text file.
  • Auditing your data. Sometimes you want to see exactly what the generated database contains after generation — every field, every array, every nested structure — in a format you can search through and verify.
  • Version control. JSON files diff cleanly in Git, SVN, and every other version control system. Export your database as JSON and commit it alongside your project, and you get a human-readable history of every change to your game data over time.

Using the window is straightforward. Drag any generated database asset into the database field. The window auto-detects which type of database you have assigned — Resource, Generator, Upgrade, Prestige, or Achievement — and configures the export accordingly. Choose your output path, click Export, and the JSON file is written to disk.

Auto-Detection

The Database Export Window identifies your database type by checking which data source interface it implements. You do not need to tell it whether your database is a resource database or a generator database — it figures that out automatically and labels the export file accordingly.

Importing JSON

Getting content back into the forge is just as streamlined as getting it out. Each forge's Definitions step (Step 2) has an import button that opens the import dialog. From there, the process is designed to be fast and forgiving — the toolkit catches mistakes before they become problems.

1

Load Your JSON

Click the import button in Step 2 of any forge wizard. You can browse to a JSON file on disk or paste JSON directly into the import dialog. Both methods produce the same result — the toolkit parses the content and prepares it for validation.

2

Automatic Validation

Before any data touches your wizard, the toolkit validates every entry in the imported JSON. This is thorough validation, not just a syntax check. The import process:

  • Checks that every resource code referenced in costs, production, and rewards actually exists in your linked resource databases
  • Validates that enum values (scaling types, cap modes, effect types, condition types, comparison operators) are real values from the toolkit's enum definitions
  • Flags missing required fields — every entry needs at minimum a code and a name
  • Detects duplicate codes within the import file
  • Warns about codes that already exist in your wizard (so you can decide how to handle conflicts)
  • Validates nested structures like milestones, prerequisites, rewards, reset rules, and permanent bonuses

If the validation finds problems, it reports them clearly — which entry, which field, what is wrong, and what it expected instead. You fix the issues in your source JSON and re-import. Nothing is modified in your wizard until validation passes.

3

Conflict Resolution

When the imported JSON contains entries whose codes match entries that already exist in your wizard, the toolkit asks you how to handle the overlap. You get three options:

  • Replace — overwrite existing entries with the imported versions. Use this when you have updated entries externally and want the new data to take precedence.
  • Cancel — abort the entire import. Nothing changes. Use this when you realize the import file is not what you intended.
  • Keep existing + Add new — skip entries that already exist and only add entries with new codes. Use this when you are adding a batch of new content to an existing database without touching what is already there.
4

Review and Generate

After import, your new entries appear in the wizard's builder (Step 3) alongside any existing entries. You can review them, make adjustments, and then proceed to generation as normal. The imported entries are fully editable — they are real wizard entries now, not read-only imports.

Link Your Databases First

If your JSON references resource codes (which nearly all generator, upgrade, prestige, and achievement entries do), make sure you have linked the relevant resource databases in Step 1 of the forge wizard before importing. The validation step checks resource codes against your linked databases. If no databases are linked, every resource code reference will be flagged as invalid.

JSON Structure

Understanding what the JSON looks like makes it easy to create entries in any tool. The format is straightforward — flat objects with clearly named fields. Here is what a resource entry looks like:

Resource Entry

{
  "code": "GOLD",
  "name": "Gold",
  "description": "The primary currency of the realm",
  "startingAmount": 0,
  "maxCap": 0,
  "capMode": "None",
  "displayFormat": "Short",
  "displayPrecision": 0,
  "categories": [{"name": "Resource Type", "value": "Currency"}],
  "flags": [{"name": "Persists Through Prestige", "value": false}],
  "numerics": [{"name": "Display Order", "value": 1}],
  "texts": [{"name": "Short Name", "value": "G"}]
}

Every resource entry has a code (the unique identifier used by every other forge to reference this resource), a name (the display name players see), and a description. The startingAmount is what the player begins with. The maxCap sets an upper limit (0 means unlimited). The capMode controls what happens as a resource approaches its cap — None, Hard (stops at cap), Flat (reduced rate near cap), Curve (smooth falloff), or Step (tiered efficiency thresholds). The displayFormat determines how numbers are shown — Short uses K/M/B/T suffixes, Scientific uses exponential notation, Full shows the complete number. The displayPrecision controls decimal places.

The four arrays at the bottom — categories, flags, numerics, and texts — are your custom dynamic properties. Their names and available values come from whatever you defined in Step 2 of the Resource Forge. If you defined a "Resource Type" category with options like "Currency", "Premium", and "Material", then each entry specifies which option applies. These properties let you filter, sort, and query your data at runtime in ways that are specific to your game.

Generator Entry

{
  "code": "MINE",
  "name": "Gold Mine",
  "description": "Digs for gold deep underground",
  "maxLevel": 0,
  "productionMode": "Continuous",
  "productionInterval": 1.0,
  "production": [
    {"resourceCode": "GOLD", "baseAmountPerSecond": 1.5}
  ],
  "costs": [
    {
      "resourceCode": "GOLD",
      "baseAmount": 15,
      "scalingType": "Exponential",
      "scalingFactor": 1.15
    }
  ],
  "prerequisites": [],
  "milestones": [
    {
      "levelThreshold": 25,
      "bonusType": "Multiply",
      "bonusValue": 2.0,
      "bonusDescription": "x2 Gold production"
    }
  ]
}

Generator entries are richer because they define the core economic engine of your game. The production array lists every resource this generator produces and how much per second at base level. The costs array lists every resource it costs to buy, with a base amount and a scaling formula. In this example, the Gold Mine costs 15 gold at level 1 and scales exponentially with a factor of 1.15 — the same formula Cookie Clicker uses. At level 10, that cost becomes roughly 61 gold. At level 50, it is about 16,367 gold. The interactive preview sliders in the wizard show you these exact numbers before you generate.

The productionMode field determines how the generator produces resources. Continuous means resources flow every tick (like Cookie Clicker). Timer means resources arrive in batches after a countdown (like Adventure Capitalist), and the productionInterval sets how many seconds each cycle takes.

The prerequisites array defines conditions that must be met before the generator becomes available — reach a certain resource amount, level up another generator, purchase a specific upgrade. The milestones array defines level thresholds that grant bonuses — at level 25, this mine doubles its gold production.

The same pattern applies to upgrade, prestige, and achievement entries. Each has a code, a name, its type-specific fields (effects for upgrades, formulas for prestige, conditions for achievements), and dynamic property arrays. The Light JSON export from each forge gives you the complete field reference for that forge's entry type.

Start from Real Examples

The fastest way to learn the JSON format is to open one of the demo game's JSON source files. Every demo includes its complete JSON data for all five forges. Find an entry that is similar to what you want to create, copy it, and modify the values. You do not need to memorize the field names — just work from examples.

The Demo Game Pipeline

All four demo games included with Simple Idle Forge were created using the exact JSON pipeline described on this page. Not some of the content — all of it. Every resource, every generator, every upgrade, every prestige layer, and every achievement in every demo was authored as JSON, imported into the forge wizards, and generated into playable databases. Here is how that pipeline works, step by step.

1

Design the Economy in JSON

Each demo started as a set of JSON files — one per forge — describing the complete game economy. Resources were defined first (currencies, materials, prestige points, vital stats), then generators (buildings, workers, zones, crafting stations), then upgrades (multipliers, automation, unlocks), then prestige layers (reset cycles with permanent bonuses), and finally achievements (milestones, challenges, secret goals). The JSON files reference each other by code — a generator's cost references a resource code, an upgrade's effect targets a generator code, and so on.

2

Import into the Forge Wizards

Each JSON file was imported into the corresponding forge wizard. Resources first (since every other forge references them), then generators, then upgrades, then prestige, then achievements. The import validation caught typos in resource codes, flagged missing fields, and ensured every cross-reference pointed to a real entry. A few corrections were made and the import was re-run until everything validated cleanly.

3

Generate the Databases

With all entries imported and validated, each forge's Generate button produced the final database assets. The Resource Forge generated the resource enum and database. The Generator Forge generated the generator enum, database, and milestone data. And so on through all five forges. Each generation takes a few seconds — the bulk of the time is the content creation, not the database generation.

4

Wire the Runtime

Each demo has a runtime manager script that initializes the toolkit's runtime components (resource pool, generator manager, upgrade tracker, prestige manager, milestone tracker, buff manager, auto-purchaser, and statistics tracker) from the generated databases. The manager reads the databases, wires up the UI, and starts the game loop. The databases are assigned to the manager through public fields in the Unity Inspector — no code changes needed when the data changes.

5

Iterate

When the economy needed tuning — a generator cost too steep, a prestige formula too generous, an achievement threshold too easy — the JSON source files were updated, re-imported, and the databases regenerated. The runtime code did not change at all. Data-driven design means your game logic stays stable while your content evolves.

The JSON source files for all four demos are included in the package so you can study them. They are real production data — the same files that produced the playable games you can run in the demo scenes. Open them, read the structure, see how resources reference each other, how costs scale, how prestige layers chain together. These files are the best reference for learning the JSON format, because they are not simplified examples — they are complete, working game economies.

Content Counts Across the Demos

Simple Kingdom: 7 resources, 8 generators, 20 upgrades, 1 prestige layer, 20 achievements.
Factory Tycoon: 12 resources, 10 generators, 24 upgrades, 2 prestige layers, 25 achievements.
Survival Idle: 16 resources, 12 generators, 24 upgrades, 3 prestige layers, 30 achievements.
RPG Idle: 19 resources, 14 generators, 27 upgrades, 4 prestige layers, 35 achievements.

Batch Icon Assignment

Once your databases are generated, you will probably want to assign icons to your entries. If you have a handful of entries, dragging sprites one by one in the Inspector is fine. But if you have 30 generators, 50 upgrades, and 40 achievements, that becomes tedious fast. The Batch Icon Assignment window handles this in bulk.

Open it at Window → Living Failure → Simple Idle Forge → Batch Icon Assignment.

1

Point to Your Sprites

Assign a folder that contains your icon sprites. These can be PNG, JPG, PSD, or any format Unity imports as a Sprite. The window scans the folder and lists every sprite it finds.

2

Point to Your Database

Assign the generated database you want to add icons to. The window reads all entry codes from the database.

3

Auto-Match

The window automatically matches sprites to entries by comparing filenames to entry codes. The matching is flexible — it handles the common naming differences between sprite files and game codes:

  • GOLD_MINE.png matches the GOLD_MINE entry
  • gold-mine.png matches the GOLD_MINE entry (case insensitive, dashes converted to underscores)
  • Gold Mine.png matches the GOLD_MINE entry (spaces converted to underscores, case insensitive)
  • goldmine.png matches the GOLD_MINE entry (underscores stripped for comparison)

Matched entries show a green checkmark. Unmatched entries show a dropdown where you can manually select a sprite from the scanned folder.

4

Apply

Click Apply All Matches and every matched entry gets its icon assigned in one operation. The database asset is saved automatically. Open the database in the Inspector and you will see icons on every entry that had a match.

Naming Convention

The easiest way to make auto-matching work perfectly is to name your sprite files using the same codes as your entries. If your generator codes are MINE, LUMBER_MILL, and QUARRY, name your sprites MINE.png, LUMBER_MILL.png, and QUARRY.png. One hundred percent match rate with zero manual overrides.

Tips for the JSON Pipeline

After building four complete demo games with this pipeline, here are the practices that make the workflow smooth and reliable.

Export Your Schema First

Before you create a single entry, open the forge wizard, set up your property definitions in Step 2, and export in Light mode. This gives you a clean template that shows exactly what fields are available, what types they expect, and what enum values are valid. Use this template as the reference for all your content generation. Every field name, every valid value, every nested structure is documented in the export. You never have to guess.

Use Consistent Naming

Stick to UPPER_SNAKE_CASE for codes (GOLD_MINE, FIRE_SWORD, PRESTIGE_RESET) and Title Case for display names ("Gold Mine", "Fire Sword", "Prestige Reset"). Codes are identifiers that the system uses internally — they need to be unique, predictable, and easy to reference in other entries. Display names are what players see — they should read naturally. Keeping these two conventions separate prevents confusion when cross-referencing between forges.

Group Related Entries

Organize your JSON files so that related entries sit together. Put all your currency resources in one block, all your crafting materials in another, all your prestige currencies in a third. Put early-game generators before mid-game generators before late-game generators. This makes the file easier to read, easier to review for balance, and easier to update when you need to adjust a tier of content. The import does not care about order, but your future self will appreciate the organization.

Validate Before Importing

The import tool catches errors, but it is faster to get things right before you import. Common mistakes include mistyped resource codes (the generator references GOLDD instead of GOLD), invalid enum values (writing Exponetial instead of Exponential), and missing commas in JSON arrays. A quick syntax check in your text editor or a JSON validator catches these instantly. The import tool will catch them too — it just takes an extra round trip.

Keep Your Source Files

Your JSON files are your content source of truth. Keep them alongside your Unity project, check them into version control, and treat them as first-class project assets. If you ever need to regenerate your databases (because you changed a property definition, or you are moving to a new Unity project, or you accidentally deleted a generated asset), the JSON files let you rebuild everything from scratch in minutes. The forge wizards and generated databases are outputs. The JSON files are the inputs you cannot afford to lose.

Iterate in Small Batches

You do not need to import your entire game at once. Start with resources and a few generators. Import, generate, play, and see how it feels. Then add more generators, import your upgrades, test again. Then prestige, then achievements. Small batches let you catch balance issues early and keep each import manageable. The four demo games were all built incrementally — resources first, then generators, then layer by layer until the complete economy was in place.

Round-Trip Workflow

The JSON pipeline is fully round-trip. Export your current database as Full JSON, make changes to the exported file, and import it back. Your edits overwrite the existing entries (if you choose Replace) or sit alongside them (if you choose Keep + Add). This means you can always move your data out of Unity, work on it externally, and bring it back — in either direction, as many times as you need.