scmJS
scmJS is a map editor and replay viewer for StarCraft, Brood War and StarCraft:
Remastered, modelled on StarEdit, SCMDraft 2 and StarForge. It runs in the browser and as
a desktop app.
It opens .scm and .scx maps (and a bare .chk scenario) and .rep replays, draws
them with the game’s own terrain and unit graphics, classic or Remastered, and saves maps
the game plays. Anything in a map it does not understand is written back untouched, so a
map loses only what you change.

Beta. This editor needs to be extensively tested. Keep backups of maps you care about,
and check anything important in-game before you rely on it.
The user guide covers everything the editor does, starting with your
first map. It is also at
docs.scmjs.dev, with a search box.
Features
scmJS edits terrain, units, locations and triggers like any StarCraft editor. It also has
the following. Items marked Browse Plugins are not installed at first; add them from
Plugins ▸ Browse Plugins….
- Classic or Remastered graphics. Pointed at a Remastered installation, the editor
draws with Remastered’s terrain, units and moving water; View ▸ Remastered Graphics
switches back. See Classic or Remastered
graphics.
- Replays. File ▸ Open Replay… opens a
.rep on the map it was played on, with the
players’ orders on a timeline, build orders and the chat. At scmjs.dev the game also
plays back, with an analysis of fights, economy and tech. See
Replays.
- Test in the game or the browser. Tools ▸ Test Map puts the map in the game’s Maps
folder; at scmjs.dev, Tools ▸ Test in Browser plays it in a browser tab from your own
StarCraft files. See Test Map.
- Mods. A mod such as Cosmonarchy BW plays in the browser at
scmjs.dev/play with its own plugins, optionally against a bot
made for it, and the editor plays back and analyses its replays. The editor also makes
maps for a mod, showing its units under their own names and the terrain its tilesets
add, and
scmjs mod keeps a mod as a folder of text you can edit and keep in git. See
Mods.
- A command line.
scmjs looks inside maps and replays, checks maps on every push
with a GitHub Action, plays a map’s triggers in the game, and builds and plays bots. See
the command line guide.
- Your own AI app on your maps. Claude Desktop, Claude Code, Cursor and other apps
read, check and change a map as you ask. Claude Desktop sets it up from one file, with
no terminal needed. If the map is open in the editor, each change arrives there as one
undo step. See AI tools.
- Several people on one map. Share the open map and anyone with the link edits it with
you, live. See Editing a map together.
- Bots. Play against a computer player somebody wrote on the play page, or write one:
a JavaScript bot is one file, and a BWAPI bot written in C++ can be built into one.
scmjs bot plays them against each other from a terminal. See Bots.
- A library for your own tools.
@scm-js/core is the editor’s map code as an npm
package, for scripts that read and change maps. See The library.
- Triggers as code. TrigScript writes triggers in TypeScript,
with tests and a simulator; for Remastered it also builds code that runs in the game
itself.
- AI on your own key. With your Anthropic API key, an assistant reads and edits the
open map with you, and Tools ▸ AI lays out maps, writes triggers and briefings, and
reviews a map. The prompts are public in
ai-engine. See The AI.
- Triggers as a graph. Trigger Map (Browse Plugins) shows which triggers set and
read each switch, death counter and location, and what is never set, read or run.
- Walkability. View ▸ Walkability (Ctrl+Shift+W) draws islands, regions, chokes with
their widths, and distances between start locations.
- Damaged and protected maps. Repair checks each map as it opens and fixes what the
game would; Section Explorer (Browse Plugins) shows the file byte by byte. See
Protected and damaged maps.
- Unknown data kept on save. Unknown or malformed sections and unnamed archive files
are written back as they were read, unless the game would refuse the map as it stands.
See Opening and saving maps.
- Terrain from a picture. File ▸ Import ▸ Terrain from Image… turns an image into
terrain, cliffs and shores included. See Plugins.
- Stamps. Save a ramp, a bridge or a mineral line once and lay it down on any map. See
Cut, copy and paste.
- Doodads into terrain. Convert Doodad to Terrain turns a doodad into ordinary tiles
you can edit. See Doodads.
- Wider ramps, longer bridges. Drag a ramp or a bridge as you place it and it
stretches along its cliff or its deck. View ▸ Seam Overlay marks the joins that show,
the Heal brush swaps them for tiles that play the same, and Pin protects hand-laid
ground from the isometric brush. See Stretching a ramp or a
bridge and Heal.
- A symmetry report. Tools ▸ Symmetry… says how alike the sides of a map play under
each mirror and turn, and lists the places that differ. See
Symmetry.
- Timelapse. Timelapse (Browse Plugins) records the map change by change and exports
a GIF or WebM video. See Plugins.
- Maps from scmscx.com. File ▸ Find on scmscx.com… searches the community map archive
and opens the map you pick. See Opening a map.
- Recovery and backups. Maps open in tabs, unsaved work is kept in recovery copies,
and the version a save replaced is kept as a
.bak or under File ▸ Previous Versions.
See Saving and Recovery copies.
- English or Korean. Preferences ▸ General switches the language. See Keyboard and
preferences.

Getting started
- Open the editor.
- In the browser at scmjs.dev/editor. Nothing to install,
and your maps stay on your own disk.
- As a desktop app for Windows, macOS and Linux, from the releases
page. It opens a map on a double-click and starts the game for Test Map.
- In a container, for a server on your own network.
- Point it at your StarCraft folder. The game’s graphics do not ship with the editor.
On first use it asks for your StarCraft installation, classic (1.16) or Remastered, and
reads the graphics from there once. Without StarCraft installed, Blizzard’s free map
editor download is enough to edit maps and watch replays; testing a map or playing
needs StarCraft installed.
Installing has each step in full. Then start with the guide’s first
map.
Documentation
The files below are also published at docs.scmjs.dev, with a
search box and a reference for every call in the plugin API. The site is built from the
same release as the editor at scmjs.dev/editor.
| Document |
Covers |
| docs/guide.md |
The user guide: a first map, then each layer and dialog, testing and saving, replays, sharing, plugins and preferences |
| docs/installing.md |
The hosted editor, the desktop app, the container, and getting the game’s graphics |
| docs/trigscript.md |
TrigScript, triggers written as TypeScript: the script window, tests, programs that run in the game, examples and the reference |
| docs/trigscript-language.md |
The language of TrigScript programs: values, arrays, functions, classes, errors, tasks, units, events, input, text, sounds and libraries |
| docs/trigscript-library.md |
The modules that come with TrigScript (maths, chance, timers, signals, menus, cutscenes, fog pictures, pixel screens, music, workers, spells), with an example of each |
| docs/triggers.md |
Every trigger condition and action: what it does, its arguments, its text form and where it is stored |
| docs/game-data.md |
Where the graphics come from, what is kept, mods as data sets, and how the pictures are drawn |
| docs/file-formats.md |
What the editor does with a map file: what it preserves, what Save can strip, revisions, protected maps |
| docs/chk-format.md |
Every section of the scenario file, byte by byte |
| docs/plugins.md |
Writing and installing plugins; the plugin API |
| docs/cli.md |
The scmjs command line, by task: getting started, looking inside a map, making and changing maps, maps in git and CI, running a map’s triggers in the game, a melee map’s layout and balance, replays, mods, sharing, bots and plugins, and a reference of every command |
| docs/ai-tools.md |
AI apps on your maps through scmjs mcp: setting up Claude Desktop and the others, what to ask, working on the map open in the editor, when something goes wrong, and every tool |
| docs/bots.md |
Bots on the play page and from the command line: playing against one, a first bot in JavaScript, bringing a BWAPI bot, bots for mods, how good the sample bots are, what is not there yet, and the reference for JavaScript bots |
| docs/mods.md |
Mods: a mod read as its makers ship it, kept as a folder of PyMS text and PNG sheets, checked, compared, packed back into an MPQ and played |
| docs/core.md |
@scm-js/core, the editor’s map code as an npm package for scripts and tools of your own |
| docs/development.md |
Running from source, the desktop app and the container, releases, contributing |
| ATTRIBUTION.md |
Provenance of adapted algorithms, tables and dependencies |
Other repositories
The plugins, the plugin registry, the website, the documentation site, the replay and mod
readers (@scm-js/replay, @scm-js/mod), the bot builder and the package-manager
installers each have a repository of their own. The scm-js
organisation lists them all, with what each one is.
License
The original scm-js source is MIT-licensed; see LICENSE. That license does not
cover upstream code, packages, research, names or game data.
ATTRIBUTION.md records where each of those came from, and source-level
credit sits beside the code it applies to.
StarCraft and Brood War are trademarks of Blizzard Entertainment. This is a fan project,
not affiliated with or endorsed by Blizzard Entertainment.
评论