EARTH GAMESVARA LIGIPÄÄS
Home›Developers›Guides
DEVELOPER GUIDES15 GUIDES

Guides & recipes

How to build the common patterns with complete, verified code that passes earthgames check as written.

Make it play anywhere

Most games should work in any town on Earth, because that is where your players are. The trick is to never write a coordinate. Put things where the players are instead.

  • Relative to a player or a point: eg.world.offset(player, 30, -60) is the point 30 m east and 60 m north of them.
  • At real places near them: await eg.world.placesNear(player, { minM: 200, maxM: 1500, kinds: ["shop"] }) gives named places from the map, each on the road in front of it.
  • By rule: a spawner without at keeps characters around the players wherever they go.
  • As they move: onPlayerArea fires each time a player comes into a new area (squares of about 1.5 km), the one they start in included.
make-it-play-anywhere.js
js
export default {
  async onPlayerArea(player, area) {
    // Three real shops in this area become places to visit.
    const shops = await eg.world.placesNear(area.center, { maxM: 1000, kinds: ['shop'], max: 3, seed: area.id });
    for (const s of shops) eg.entities.add({ id: 'shop-' + s.id, kind: 'zone', at: { lat: s.lat, lon: s.lon }, radius: 8, label: s.name, style: 'pickup', trigger: {} });
  },
  onZone(player, entityId, what) {
    if (what === 'enter') { eg.ui.toast(player, 'Visited.', 'good'); eg.entities.remove(entityId); }
  },
};

eg.world.onRoad(point) tells you whether a point is on a road, and answers null where the map is not built yet. earthgames check warns when a game that says it plays anywhere has fixed coordinates in it.

A game that needs one place says so in game.json with "area": see the game.json reference.

Zones, markers and things to pick up

An entity is a zone (a ring on the ground players walk or drive into) or a marker (a beacon). eg.entities.add returns its id.

  • trigger: {} makes a zone fire onZone with "enter" and "leave". trigger: { dwellS: 3, maxSpeed: 2 } also fires "dwell" when a player stays 3 seconds at under 2 m/s: a delivery, a capture point.
  • interact: { verb: "Open" } gives it an F prompt and fires onInteract.
  • visibleTo: player makes it that player's own: nobody else sees it.
  • style picks its color (the list is in the reference), label its text, radar: true puts it on the minimap.

A thing to pick up is a small zone you remove when someone walks into it:

zones-markers-and-things-to-.js
js
let n = 0;
function dropMedkit(at) {
  eg.entities.add({ id: 'med-' + (++n), kind: 'zone', at, radius: 1.5, style: 'heal', label: 'Medkit', trigger: {} });
}
export default {
  onStart() { eg.combat.enable(); },
  onPlayerJoin(player) { dropMedkit(eg.world.offset(player, 10, 0)); },
  onZone(player, entityId, what) {
    if (what !== 'enter' || !entityId.startsWith('med-')) return;
    eg.entities.remove(entityId);
    eg.combat.heal(player, 50);
    eg.audio.cue(player, 'ui.job_load');
  },
};

Characters and spawners

Your game's characters are moved by the platform: you say what kinds there are and what they do, and you hear what happens to them in onNpc. They work in private games (every game you make is one).

First define the kinds, once, in onStart. Left out, model gives each one a different everyday person; the models are listed in the reference.

characters-and-spawners.js
js
export default {
  onStart() {
    eg.npcs.kinds([
      { id: 'guard', name: 'Guard', brain: 'guard', health: 120, sight: 30, attack: { range: 1.5, damage: 15, cooldownS: 1.2 } },
      { id: 'runner', name: 'Runner', brain: 'chase', runSpeed: 6, health: 40, sight: 150, attack: { range: 1.4, damage: 8, cooldownS: 1 } },
    ]);
    // A crowd that follows the players around: never closer than 40 m when it appears.
    eg.spawners.add({ id: 'pack', kind: 'runner', capNear: 8, capTotal: 40, perSecond: 1, where: { minFromPlayersM: 40, maxFromPlayersM: 90 } });
  },
  async onPlayerJoin(player) {
    // One guard, placed by hand, 20 m east of the player.
    const at = eg.world.offset(player, 20, 0);
    await eg.npcs.spawn('guard', { lat: at.lat, lon: at.lon, tag: 'gate' });
  },
  onNpc(e) {
    if (e.ev === 'died' && e.player) eg.ui.toast(e.player, 'Down: ' + e.kind, 'good');
  },
};
  • Two kinds of spawner. With at it keeps count characters alive around that spot. Without at it keeps up to capNear around each player (and capTotal in all), appearing out of the way: between minFromPlayersM and maxFromPlayersM from every player.
  • where: { roadClass: ["residential", "footway"] } makes them appear on roads of those types (the map's road types, as in OpenStreetMap). hours: [20, 6] makes a spawner work only at night, by the sun where the game is played.
  • eg.spawners.enable, setDensity and burst are how a game makes waves: switch spawners on for a wave, off for the break.
  • eg.npcs.setBrain(id, "goto", { target: point }) sends one somewhere; "patrol" with route: [points] walks a round; "chase" with target: player picks who it goes for.
  • onNpc events: "spawned", "saw" and "lost" (a player), "attack", "reached", "died" (with where, and the player who did it), "gone".
  • With combat on, a character's attack hurts the player by itself. Pass npcDamage: false to eg.combat.enable to decide that yourself in onNpc ("attack").

The script never moves characters step by step: there is no per-frame handler, and that is what lets hundreds of them run at once. Change what they do when something happens.

Combat and what players carry

One call switches combat on: every player gets health (100), a health and weapon bar, and the loadout you give. Shots and swings are checked on the server.

combat-and-what-players-carr.js
js
export default {
  onStart() {
    eg.combat.enable({ respawnS: 8, loadout: { pistol: 48, bat: 1, medkit: 2 } });
  },
  onPlayerDied(player, hit) {
    eg.ui.toast(null, player.name + ' is down.', 'warn');
  },
  onPlayerRespawn(player) {
    eg.inventory.setLoadout(player, { pistol: 48, bat: 1, medkit: 2 });
  },
  async onUi(player, what) {
    // "medkit" is a key of the game's own: "actions": [{ "id": "medkit", "label": "Use a medkit", "key": "KeyH" }]
    if (what.from !== 'action' || what.id !== 'medkit') return;
    const has = await eg.inventory.get(player);
    if (!has.medkit) return eg.ui.toast(player, 'No medkits left.', 'warn');
    eg.inventory.take(player, 'medkit', 1);
    eg.combat.heal(player, 60);
  },
};
  • Weapons are bat, pistol, smg and shotgun; everyone always has fists. A gun's number is its rounds (pistol holds up to 120). Their damage and range are in the reference.
  • Items of your own are any lowercase id ("key", "medkit", "gem"). The platform counts them and shows nothing: what they do is up to your script.
  • Down and back: at 0 health a player is down for respawnS seconds (5; 0 means until you call eg.combat.respawn), then back with full health and safeS seconds (3) in which they cannot be hurt.
  • Players hurting players needs pvp: true (and say so in game.json: "content": { "pvp": true }). Teammates cannot hurt each other unless friendlyFire: true.
  • Your own damage: await eg.combat.damage(player, 20, { why: "fall" }) for traps and rules of your own; eg.fx.explosion(at, { damage: 60, radius: 8 }) hurts players and characters near it.
  • Armor (eg.combat.setArmor, 0 to 100) takes 60 % of each hit until it is used up.

Blood. Hits draw blood only when your game.json says "content": { "violence": "strong", "blood": true }, and only for signed-in players of 17 or older who turned it on in their settings. Everyone else sees the same game without it. You do not need to check any of this in your script.

HUD, menus, keys and sounds

You never write HTML. You send plain data and the platform draws it, in each player's own language of units.

  • eg.ui.toast(player, text, tone): a short message. null in place of the player sends it to everyone.
  • eg.ui.hud(player, parts): the game's card on the screen, replaced whole each time you send it.
  • eg.ui.card(player, card): a result card with buttons, shown until closed.
  • eg.ui.menu(player, menu): a panel with a list of choices and optional tabs.
  • eg.ui.waypoint(player, at): the GPS guides them there.
  • eg.audio.cue(player, id): a short sound from the library.
hud-menus-keys-and-sounds.js
js
const ends = new Map();
export default {
  onPlayerJoin(player) {
    const goal = eg.world.offset(player, 0, -400);
    ends.set(player.id, eg.world.now() + 120000);
    eg.ui.waypoint(player, goal, { hint: 'You made it.', hintM: 15 });
    eg.ui.hud(player, [
      { type: 'title', text: 'Courier' },
      { type: 'distance', to: goal, text: 'to the drop' },
      { type: 'timer', until: ends.get(player.id), text: 'left' },
      { type: 'button', id: 'shop', label: 'Shop' },
    ]);
  },
  onUi(player, what) {
    if (what.from === 'hud' && what.id === 'shop') {
      eg.ui.menu(player, { id: 'shop', title: 'Shop', items: [
        { id: 'boots', title: 'Fast boots', detail: 'Costs 3 gems', button: 'Buy' },
        { id: 'map', title: 'Map', detail: 'You have it', disabled: true },
      ] });
    }
    if (what.from === 'menu' && what.id === 'shop' && what.item === 'boots') {
      eg.ui.menu(player, null);
      eg.ui.toast(player, 'Bought.', 'good');
    }
  },
};
  • Text in a HUD part may hold {dist:1234}, {km:2.5} or {time:95}: each player sees miles or kilometers as they chose.
  • A button with action: "signin" opens the sign-in dialog for a guest; "close" closes the card; "waypoint" points their GPS back at the waypoint you set.
  • Your own keys go in game.json: "actions": [{ "id": "medkit", "label": "Use a medkit", "key": "KeyH" }]. A press fires onUi with { from: "action", id: "medkit" }. "key": "panel" is the game's main key (J): open your menu on it.
  • Sending the same HUD many times a second wastes your message budget. Send it when something changed.

Rounds, teams and scores

A match is yours to shape: name its parts, lock the door while a round runs, start over when it ends.

rounds-teams-and-scores.js
js
const ROUND_S = 180;
export default {
  onStart() {
    eg.teams.define([{ id: 'red', name: 'Red', color: 'red' }, { id: 'blue', name: 'Blue', color: 'blue' }]);
    eg.instance.setPhase('lobby');
    eg.timers.after(20, () => {
      eg.teams.auto();
      eg.instance.setPhase('round'); eg.instance.lock();
      eg.ui.hud(null, [{ type: 'teams' }, { type: 'timer', until: eg.world.now() + ROUND_S * 1000, text: 'left' }]);
      eg.timers.after(ROUND_S, async () => {
        const teams = await eg.teams.all();
        const best = teams.sort((a, b) => b.score - a.score)[0];
        for (const p of eg.players.all()) {
          eg.ui.card(p, { title: best.name + ' wins', lines: teams.map(t => t.name + ': ' + t.score), seconds: 10 });
          if (p.team === best.id) eg.scores.add(p, 100);
        }
        eg.timers.after(10, () => eg.instance.restart());
      });
    });
  },
  onPlayerDied(player, hit) {
    const by = hit.by && eg.players.get(hit.by);
    if (by && by.team) eg.teams.addScore(by.team, 1);
  },
};
  • eg.scores.add(player, points) puts a signed-in player on your game's weekly and all-time boards, shown on the game's page. It answers null for a guest.
  • eg.scores.setBest(player, "track-7", ms) keeps best times on boards you name.
  • Scored runs: call await eg.players.startRun(player) before a run that ends with a score, and eg.players.finishRun(player) when it is completed. Free players have a number of runs a day across Earth Games; when it answers false the platform has already told them.
  • eg.instance.restart() starts the script again from onStart with the same players; saves are kept. eg.instance.end() sends everyone back to the shared world.
  • eg.players.teleport(player, point) moves a player at once: the start of a round, a respawn point.

Saves and worlds that go on

There are two kinds of memory, and plain variables are neither: they are gone when the game closes.

  • Per player, in any game: eg.saves.setPlayer(player, "best", 41.5) and await eg.saves.getPlayer(player, "best"). It follows that player into every match and world of your game.
  • Per world, in persistent games: set "instance": { "kind": "persistent" } in game.json, save with eg.saves.set("day", 3), and read everything back in onLoad when the world opens again.
saves-and-worlds-that-go-on.js
js
let day = 1;
export default {
  onLoad(saved, info) {            // before onStart; info.fresh is true for a brand-new world
    day = saved.day || 1;
    // info.version is the version of your game that saved this world: convert old saves here.
  },
  onStart() {
    eg.timers.every(60, () => eg.saves.set('day', ++day));
  },
  async onPlayerJoin(player) {
    const visits = ((await eg.saves.getPlayer(player, 'visits')) || 0) + 1;
    eg.saves.setPlayer(player, 'visits', visits);
    eg.ui.toast(player, 'Day ' + day + '. Visit ' + visits + '.');
  },
};
  • Each saved world has an invite code that never changes, so friends can come back to it later.
  • A world is saved as it goes, when the last player leaves, and before the server restarts. After a restart the script starts again: onLoad, then onStart. Anything you did not save is gone, so save what matters when it changes.
  • A match that is running when the server restarts ends with a notice, with no penalty to anyone.
  • The sizes and how long an unused world is kept are in the reference, under Limits.

Races

The platform times races and draws the gates, the start lights and the clock. Your script says where, and what a finish is worth.

races.js
js
export default {
  async onPlayerJoin(player) {
    const [track] = await eg.race.tracksNear(player);            // real streets near them
    if (track) await eg.race.offer(player, track.id);            // a ring on the start line; stop in it for the lights
  },
  async onRace(player, race) {
    if (race.ev !== 'finish') return;
    const r = await eg.scores.setBest(player, race.track, race.ms);
    eg.ui.toast(null, player.name + ' finished in ' + (race.ms / 1000).toFixed(2) + ' s' + (r && r.improved ? ', a personal best' : ''));
  },
};
  • For a course of your own, await eg.race.course(points, { name, laps }) puts gates through the points you give (100 m to 20 km) and returns a track to offer.
  • Players of your game who line up together start together, and race.place says where each finished.
  • A race ends with ev: "void" when it cannot count: the player teleported, flew, got out, or took too long. race.reason says which.
  • player.car is { id, cls, top }: race.par is a good time for that class of car.

Windows, modals and prompts

Beyond small HUD cards, scripts can dock multi-block windows (eg.ui.window) on the left, right, or center of the screen, and pause an interaction with awaitable modal dialogs (eg.ui.confirm, eg.ui.prompt, eg.ui.choose, eg.ui.form) that return the player's answer directly to your async handler.

windows-modals-and-prompts.js
js
export default {
  async onInteract(player, id) {
    if (id !== 'hq') return;
    const role = await eg.ui.choose(player, {
      title: 'Pick your shift role',
      options: [
        { id: 'medic', label: 'Field Medic', detail: 'Starts with medkits' },
        { id: 'driver', label: 'Interceptor', detail: 'High-speed patrol' },
      ],
    });
    if (!role) return;
    eg.ui.window(player, {
      id: 'dispatch', position: 'right', width: 'sm', title: 'Shift Active',
      blocks: [
        { type: 'stats', items: [{ label: 'Role', value: role }, { label: 'Status', value: 'Ready', tone: 'good' }] },
        { type: 'callout', title: 'Orders', text: 'Patrol the sector and watch for emergencies.', tone: 'info' },
      ],
      buttons: [{ id: 'end-shift', label: 'End Shift', style: 'danger' }],
    });
  },
  onUi(player, what) {
    if (what.from === 'window' && what.id === 'dispatch' && what.button === 'end-shift') {
      eg.ui.closeWindow(player, 'dispatch');
      eg.chat.tell(player, 'Shift ended. Return to HQ anytime.');
    }
  },
};
  • A centered window (position: "center") grabs focus like a dialog and releases pointer lock automatically; "left" and "right" panels stay docked while players move.
  • Button presses, tab switches, and closing a window fire onUi with what.from === "window", what.id, plus button, tab, item, or closed: true.
  • Awaitable modals (eg.ui.confirm, eg.ui.prompt, eg.ui.choose, eg.ui.form) resolve false or null if the player cancels, disconnects, or lets timeoutS expire.
  • Use eg.ui.banner, eg.ui.countdown, and eg.ui.hint for round starts and dramatic moments, or eg.ui.clear to wipe all scripted UI for a player cleanly.

Weather, vehicles and camera

Inside a private match you control the sky, weather, lightning, vehicle grip, camera feel, and celebratory effects. All overrides reset automatically back to players' normal settings when the game closes or restarts.

weather-vehicles-and-camera.js
js
let stormOn = false;
export default {
  onStart() {
    eg.world.setTime(22);
    eg.world.setWeather('rain');
    eg.vehicles.setHandling('sport');
    eg.vehicles.setTire(null, 'allweather');
  },
  onPlayerJoin(player) {
    eg.ui.banner(player, { title: 'Night Storm', subtitle: 'Hold onto the road', tone: 'warn', seconds: 4 });
  },
  onPlayerMode(player, change) {
    if (change.to === 'drive' && !stormOn) {
      stormOn = true;
      eg.world.lightning(player);
      eg.camera.fov(player, { kick: 6, seconds: 1.5 });
      eg.vehicles.boost(player, { strength: 1.2, seconds: 2 });
    }
  },
};
  • eg.world.setWeather takes a preset (clear, cloudy, overcast, rain, storm, snow, fog) or null to restore live real-world weather. eg.world.setTime(hour) fixes the sun between 0 and 23.99 (or null for real local time).
  • React cleanly when players enter or leave vehicles using onPlayerMode (change.from and change.to), applying per-player speed caps (eg.vehicles.setSpeedLimit), temporary nitro pushes (eg.vehicles.boost), or eg.camera.fade.
  • Celebrate finishes or capture events with eg.fx.confetti, burning hazards with eg.fx.fire, expanding pulses with eg.fx.ring, and team or broadcast chat lines via eg.chat.announce and eg.chat.team.

Translating your game

Players choose their language in Earth Games. Mark the text your game shows them with eg.t, and each player gets it in their own language: the same toast reads "Ils arrivent." for a French player and "They are coming." for everyone else. Text you do not mark is shown as you wrote it.

translating-your-game.js
js
export default {
  onPlayerJoin(player) {
    eg.ui.toast(player, eg.t('Welcome, {name}.', { name: player }));
    eg.ui.hud(player, [{ type: 'title', text: eg.t('Flag Rush') }, { type: 'counter', text: eg.t('Flags'), value: 0 }]);
  },
  onZone(player, entityId, what) {
    const left = eg.players.count();
    if (what === 'enter') eg.ui.toast(player, eg.t('{n, plural, one {# player is still out there.} other {# players are still out there.}}', { n: left }), 'good');
  },
};
  • Write the text out in quotes where you call eg.t. That is how the kit finds it. Never build it with + or a template literal: write eg.t('Hi {name}', { name }), not `eg.t(Hi ${name}). earthgames check` points at the lines that do.
  • What changes goes in as a value: {name}, {n}. A player passed as a value becomes their name. Names of people and places stay as written in every language.
  • Plurals and choices follow ICU: {n, plural, one {# flag} other {# flags}} and {team, select, red {Red wins} other {Blue wins}}. # is the number, written the way the player's language writes numbers.
  • eg.t returns the English with the values filled in, so use it anywhere text goes: toasts, HUD parts, cards, menus, entity labels and interact verbs, waypoint hints. Put HUD tokens such as {dist:1234} in as values too: eg.t('{d} to go', { d: '{dist:' + meters + '}' }).
  • The title, summary, action labels and content.notice in game.json are translated without anything more from you: on the Games page, on the game's own page, in the phone and in the game.
  • Leave out of eg.t what only you read (console.log) and what players wrote.

Your own translations go in a lang folder next to game.json, one file per language, named by its code (fr, de, pt-BR, zh-Hans). Each line is the English exactly as written in eg.t or game.json, then the translation:

translating-your-game.json
json
{
  "Flag Rush": "Course aux drapeaux",
  "Welcome, {name}.": "Bienvenue, {name}.",
  "{n, plural, one {# player is still out there.} other {# players are still out there.}}": "{n, plural, one {# joueur est encore dehors.} many {# joueurs sont encore dehors.} other {# joueurs sont encore dehors.}}"
}
  • earthgames lang fr writes lang/fr.json with every text of your game, the ones not yet translated left empty for you to fill in. Run it again after adding text: what you wrote is kept.
  • earthgames check checks every line the way the platform checks its own translations: the same {values}, the plural forms that language needs (French has a many form), and nothing too long for where it goes. A line that fails is left out, so players see the English, and check says why. It also lists, per language, what is still in English (--all for every line).
  • earthgames dev --lang fr prints a link that opens your draft in French. --lang xa is the test language: every text that would be translated comes out accented and longer, so English left on the screen is text you have not marked.
  • Your files always win. Once your game is live, the platform also drafts the languages you did not write, with AI, for games that players come back to (at least 10 different players in 30 days at the start; the team can change that), the most played first. A line you add to your files later replaces the draft in your next version. Nothing of yours is ever machine-translated before the team approved the game.

Testing and the dev tools

  • earthgames check reads game.json and server.js and says what is wrong in plain words, before anything is uploaded.
  • earthgames dev pushes the game as a private draft, prints a link, and pushes again each time you save. The running game restarts with the new code in about a second, with you still in it.
  • In the game, the ` key opens the dev panel: everything your script printed with console.log, console.warn and console.error, the errors it threw (with the line), and what the platform refused and why.
  • The line at the top of the panel is the budget meter: players, entities, how long your script ran and in how many turns, how many calls it made, and whether any events were dropped. It turns amber when the script is slow.
  • Friends join your draft with its invite code: nothing has to be published to play together.
  • Time in your own drafts and in testing your own games is never counted against the free play limit.

Things that catch people out:

  • A player object is a snapshot from the moment the event fired. For where they are now, ask again: eg.players.get(player).
  • Calls that return a Promise need await. A handler may be async.
  • server.js is one file and cannot import. There is no fetch, no setTimeout (use eg.timers), no Date.now() you should rely on for game time (use eg.world.now()).
  • A handler has a few milliseconds. Do work when something happens, not in a fast timer, and never loop over every character every tick.

Publishing, review and updates

  • earthgames submit sends this version to the Earth Games team. Every game is read and played by a person before it goes live. earthgames status, or the Developer tab of your account, shows where it stands and, if it was not approved, why.
  • One version of a game waits at a time: submitting again replaces the one that is waiting.
  • A live game gets its own page at /games/<id>, a place on the Games page, and a card for sharing. You get a maker page that lists your live games.
  • To update, raise "version" in game.json and submit. Players keep getting the approved version until the new one is approved, and the team can put the previous version back if something goes wrong.
  • Players can report a game. The team can switch a game off when it breaks the maker rules; you are told why.
  • What reviewers look for: the game does what its summary says, "content" in game.json is honest, nothing in it breaks the maker rules, and the script stays inside its budgets with a full game.

Guests can play any live game inside the guest limits. Player-made games follow the same access rules as the built-in ones.

What makers earn

Games that players keep coming back to earn their makers free Earth Pass time and a higher developer role on Discord. Rewards are a thank-you from Earth Games: they are not payment, there is no revenue share, and the numbers can change. The Developer tab of your account shows this month's players and hours for each game, and the numbers in force.

A player counts for a month once they have played your game for 10 minutes that month while signed in. At most 4 hours a day are counted for one player. Guests never count, and neither does your own play.

RoleHowWhat it gives
DeveloperTurn on maker mode.The Developer role on Discord and its channels.
Published DeveloperHave one game live.4 build requests a month instead of 1.
Rising DeveloperA game with 25 players and 20 hours played in a month.1 month of Earth Pass.
Star DeveloperA game with 150 players and 200 hours played in a month.3 months of Earth Pass.
Legend Developer3 Star months in a row.6 months of Earth Pass.
  • Roles are worked out each month, so they move up and down. A slow month does not drop you at once: there is one month of grace.
  • Awards are confirmed by the team before they are given. One award is at most 12 months, and at most 24 months can be saved up.
  • Earned time lifts the play limits of a free account. If you already pay for Earth Pass, your billing is paused while earned time runs, and starts again by itself afterwards.
  • A game taken down for breaking the rules loses the roles it earned.

Asking for a place to be built. If your game needs a town that is not in the world yet, ask for it in the Developer tab of your account: 1 request a month, or 4 once you have a live game. Requests go through the same queue as everyone's votes.

Making a game without code

The Make a game app on the in-game phone (P) makes the same kind of game without a line of code. It is a good way to try an idea before writing it.

  • Pick a kind: Treasure hunt, Checkpoint race, Survival, Tag, Hold the zone, Response drill.
  • Name it and change its settings.
  • Walk to where things should be and tap to put them there. Nothing has to be placed: each kind of game puts things in sensible places by itself.
  • Add rule cards: "when this happens, do that".
  • Try it starts a private game friends can join. Send for review puts it in the same queue as every other game.

A game made this way plays anywhere unless you say "only in the place I made it", and it earns the same rewards. It cannot be edited as code afterwards; to go further, start a new game with the kit.