Warcraft III Made DotA. The Open Web Makes What's Next.
Why we abandoned legacy procedural scripting for a closed, deterministic JSON AST that runs natively in any browser and speaks fluent AI.
From Fragile Pointer Cleanup to Total JSON Evaluation
In 2002, map developers lived in fear of memory leaks from un-freed locations and unsorted group desyncs. In 2026, our closed AST treats logic as pure, immutable data where missing entities safely no-op instead of crashing.
Tower Defense Wave Spawner
Periodic unit creation and lane attack-movement
1function SpawnWave takes nothing returns nothing2 local location loc = GetRectCenter(gg_rct_Spawn)3 local location dest = GetRectCenter(gg_rct_Goal)4 local group g = CreateGroup()5 local unit u6 local integer i = 078 // Manual loop spawning creeps9 while (i < 5)10 set u = CreateUnitAtLoc(Player(1), 'ogbr', loc, 270.0)11 call GroupAddUnit(g, u)12 set i = i + 113 endwhile1415 // CRITICAL: Order group & manual pointer cleanup16 call IssuePointOrderLoc(g, "attack", dest)1718 // MISSING EITHER CAUSES PERMANENT LEAKS & CRASHES:19 call RemoveLocation(loc)20 call RemoveLocation(dest)21 call DestroyGroup(g)22 set loc = null // Reference counter bug in JASS!23 set dest = null24 set g = null25 set u = null26endfunction
- L2:Allocates C++ handle table entry for location point
- L17:Omission of RemoveLocation causes permanent handle leak lag
- L20:JASS reference counting bug: must explicitly null variables or handle is never freed
1{2 "id": "spawn_wave_periodic",3 "events": [4 { "k": "periodic", "everyTicks": 200 }5 ],6 "conditions": [7 { "k": "lt", "a": { "k": "var", "name": "wave" }, "b": { "k": "int", "v": 20 } }8 ],9 "actions": [10 {11 "k": "createUnits",12 "unitTypeId": "goblin_brawler",13 "count": { "k": "int", "v": 5 },14 "player": { "k": "int", "v": 1 },15 "at": { "k": "regionCenter", "region": "spawn" },16 "intoVar": "active_wave"17 },18 {19 "k": "order",20 "units": { "k": "var", "name": "active_wave" },21 "order": "attack_move",22 "to": { "k": "regionCenter", "region": "goal" }23 },24 { "k": "addVar", "name": "wave", "delta": { "k": "int", "v": 1 } }25 ]26}
- L10:Declarative array creation: managed by engine garbage collection
- L15:Bit-exact spatial resolution: identical integer coords across all browsers
- L18:Total evaluation: if units died mid-frame, order safely no-ops without throwing
Totality: Zero Throws
Every node in the Trigger AST is mathematically total. Querying a unit that died one tick earlier yields 0 or nullUnit. Division by zero yields zero, never NaN or Infinity. Your game never terminates mid-match.
Canonical Sorted Groups
JavaScript Set and object keys iterate based on insertion history, a notorious source of cross-client desyncs. In Shards of Stone, all unit collections are sorted numeric arrays evaluated in strict scalar order.
Bit-Exact IEEE-754 Math
Different JavaScript JITs (V8, JavaScriptCore, SpiderMonkey) optimize transcendental functions differently. We banned Math.hypot and Math.sin from simulation, replacing them with integer math and bit-exact deterministic square roots.
Comparison Matrix: 2002 vs 2026
How modern web standards, strict schemas, and deterministic execution leapfrog two decades of proprietary binary modding baggage.
| Dimension | 2002: Warcraft III JASS | 2026: Shards of Stone AST |
|---|---|---|
⚡Language & Runtime Pure AST Data | ×Imperative JASS & Lua running in a legacy C++ bytecode interpreter. Prone to dynamic type errors and unhandled exceptions. | ✓Closed declarative JSON AST (TriggerScript). Evaluated by a typed simulation loop with zero eval() and zero script execution. |
🛡️Memory & Leaks Zero Leaks | ×Manual handle pointers. Locations, unit groups, and boolexprs require RemoveLocation() and DestroyGroup(). Leaks accumulate until frame rates drop. | ✓Zero manual pointers. Units and regions are compact integer IDs managed by engine garbage collection. Zero handle lag over 5-hour matches. |
🎯Multiplayer Determinism 100% Lockstep | ×Prone to Out-of-Sync (OOS) desyncs from x87 float discrepancies, unsorted group iteration, and asynchronous local UI calls. | ✓Totality & IEEE-754 bit-exact math (detHypot). Sorted integer entity arrays, deterministic PRNG, and guaranteed lockstep across Chrome, Firefox, Safari, and native. |
🚀Distribution & Play <3s Instant Play | ×50GB client installation, fragile custom game lobbies, slow 8MB/s map downloads, and host connection dropouts. | ✓Instant URL (<3 seconds). Maps are compact compressed JSON (<200KB) served globally via CDN. Deep-link straight into a multiplayer match. |
🤖AI Authoring Prompt-to-Map | ×Hallucinated API natives and broken syntax. LLMs frequently hallucinate Blizzard natives and omit required cleanup boilerplate. | ✓AI-Native schemas and llms.txt. Strictly typed JSON contracts allow Claude 3.7 Sonnet / Claude 4, OpenAI GPT-4o / GPT-5, Google Gemini 2.0 / 2.5 Flash & Pro, DeepSeek R1, Cursor, and Windsurf to generate entire working maps in one shot. |
⚒️Modding Tools In-Browser Forge | ×Win32 WorldEdit desktop tool. Windows-only, slow initialization, external MPQ packers, and third-party script injectors required. | ✓The In-Browser Forge Studio. Full 2D canvas and 3D Three.js viewports running directly in the browser with instant Ctrl+Enter playtesting. |
🔒Security & Sandboxing Sandboxed Data | ×Closed binary execution. Map scripts have historically suffered from buffer overflow exploits and arbitrary memory execution. | ✓100% sandboxed data. Triggers are inert JSON objects inspected by the game loop. No eval, no DOM access, and zero attack surface. |
Why Modding on the Open Web Changes Everything
Zero Install, Play in 3 Seconds
Remember waiting 15 minutes for 10 players to download a 40MB custom map over Blizzard Battle.net, only for someone to drop at 99%? With Shards of Stone, maps are lightweight JSON payloads under 200KB. Click a link in Discord or Twitter, and you are in a 60 FPS deterministic RTS match in under three seconds.
AI-Native by Design (Prompt-to-Map)
Because our TriggerScript and DefOverride schemas are pure typed JSON rather than an arcane procedural scripting language, modern frontier models like Claude 3.7 Sonnet / Claude 4, OpenAI GPT-4o / GPT-5, Google Gemini 2.0 / 2.5 Flash & Pro, and DeepSeek R1 can author complete game modes without hallucinating missing APIs. Copy your map context, prompt your agent in Cursor or Windsurf, and paste the generated JSON straight into The Forge.
The In-Browser Forge Studio
No Win32 installers or Wine emulators required. The Forge is a production-grade level editor running right inside your browser. Sculpt multi-elevation terrain, paint cliff ramps, place starting buildings, assign trigger regions, and press Ctrl + Enter to immediately playtest your map in real lockstep multiplayer.
Playable Tower Defense Showcase
See what our trigger engine can do today. Our Tower Defense Showcase map features procedural enemy creep pathing across wide open mazing arenas, dynamic life counters, gold rewards on kill, wave countdown preparation timers, and multi-faction tower arsenals, authored entirely through deterministic JSON AST triggers with zero lines of engine code modified.
Don't Vibe Code an RTS From Scratch. Vibe Code on Top of Shards of Stone.
Vibe coding a 3D RTS from scratch hits an architectural brick wall at spatial partitioning, flow-field pathfinding, and bit-exact multiplayer lockstep. Build your custom units, spells, and game modes on a production-proven engine instead.
Deterministic Simulation Core
Fixed 20-tick/sec ECS loop in TypeScript, integer and IEEE-754 bit-exact math, zero garbage collection in hot loops.
Dual 2D/3D Rendering Engine
Canvas 2D isometric rendering + Three.js 3D WebGL/WebGPU with PBR materials, KTX2/Basis textures, and dynamic LOD.
High-Scale Navigation & Pathfinding
Hierarchical A* + NavGrid + vector flow fields handling thousands of units with dynamic obstacle avoidance.
Multiplayer Lockstep Netcode
WebRTC data channels & WebSockets with state-hash verification at every tick.
Spatial Audio Synthesizer
Web Audio API with real-time spatial positioning, distance attenuation, and dynamic combat sound effects.
Total JSON AST Scripting
Closed trigger syntax tree with 100% total evaluation—zero runtime crashes, zero null pointer desyncs.
Give Claude 3.7 / 4, GPT-5, Cursor or Windsurf our typed schemas
Feed /llms.txt into your agent and say: “Add a Dwarven Cryomancer hero with an icy shockwave spell and 5-tier upgrade tree.” Paste the JSON AST straight into The Forge and play immediately.
Custom 3D Models, Sprites, Audio & Splash Art
Modding in Shards of Stone extends far beyond numerical balance. Wire custom 3D GLB meshes, 2D sprite atlases, ElevenLabs spatial sound effects, dynamic music, and custom loading screen paintings directly into your map files.
3D GLB Meshes & Rigs
Hook any custom unit, tower, or boss to a 3D model via modelId. Renders with Three.js WebGL lighting, specular highlights, dynamic player team colors, and custom projectile sockets.
modelId: "dwarf_cannon_tower"2D Sprites & Selection Portraits
Classic 3/4 isometric RTS presentation. Define spriteKey and portraitKey for custom animated unit sheets, HUD unit cards, and active selection portraits with faction borders.
spriteKey & portraitKeySpatial Audio & Dynamic Music
Trigger custom sound effects on spell impact, boss spawn, or leak explosions using playSound. Dynamic musical transitions between calm wave preparation intervals and raging boss encounters.
playSound: "explosion"Custom Loading Screen Art
Give your custom campaign or scenario a signature look. Set meta.loadingScreen to any 16:9 cinematic painting or splash art to display during lobby matchmaking and pre-game staging.
meta.loadingScreen: "/assets/..."Multi-Faction Tower Whitelists
Restrict what your builders can construct using rules.allowedBuildings. Mix and match towers from Dwarf, Goblin, and Elf factions, or introduce brand new custom defense spires.
rules.allowedBuildings: [...]Pure Scripted Invaders
Turn off default macro AI base-building with rules.disableAi: true. Your creep invaders execute strictly according to your wave script, spawning on cue and marching down authored paths.
rules.disableAi: true“Make a 10-Wave Boss Arena where the Goblin Warlock raises skeletons.”
Paste the Shards of Stone schema into Claude 3.7 Sonnet / Claude 4, OpenAI GPT-4o / GPT-5, Google Gemini 2.0 / 2.5 Flash & Pro, DeepSeek R1, Cursor, or Windsurf. The model outputs a valid JSON trigger script with events, conditions, and action cascades that you can paste directly into The Forge. No missing native compiler errors, no memory leaks, no desyncs.
prompt: "Create a TriggerScript that listens to unitDies event for goblin_warlock, spawns 4 ratmen_clanrat at eventLocation, and broadcasts a soundId warning to all players."Start Forging Your RTS Worlds Today
Whether you are an RTS veteran recreating classic customs or an engineer prompting AI to author fresh game modes, the open web RTS engine is ready for you.