Making mods
A mod changes the web and phone versions of Sonic.exe The Disaster 2D on one server: new maps, game modes, characters, lobbies, pictures and sounds. The server host picks the mod; every player who joins that server downloads it on their own, so there is nothing to install.
The console and PC versions can't join a modded server, and modded servers don't appear on their server list.
What a mod can do
| Part | What it changes | Where |
|---|---|---|
| Maps | New stages for the vote: tiles, blocks, slopes, platforms, springs, rings, the exit, a background and music | maps/*.json |
| Rules | A game mode in Lua the server runs: timers, HP, rings, speed, jumps, teleports, messages, who wins | server.lua |
| Screen | Your own HUD text, bars and pictures, and sounds, drawn by each player's game | client.lua |
| Lobby | The waiting room's title, text, picture and music | lobby.json |
| Characters | A character's name, speed, acceleration, jump, gravity, damage taken, HP and sprites | characters/*.json |
| Objects | Coins, traps, enemies of your own: a sprite, a box and events in Lua | objects/* |
| Pictures and sounds | Replace any of the game's sprites or sounds, or add new ones | sprites.json, sprites/, sounds/ |
A mod can be any mix of these: only a map, only rules, or everything.
The way to make one
- Open the Mod Studio (the game's Modding item opens it too) and start a new mod from a template. The Mod Studio explains every part: maps, scripts, objects, characters, sprites, sounds and the lobby.
- Press Run to play it in the game on your own, as often as you like.
- Check it, then Export a .dmod file to try it on a server of your own (see Running a mod on a server) with friends.
- Make an account here and apply to be a modder. Once an administrator accepts you, Publish from the Studio (or upload the .dmod). Hosts can then pick it.
You can make, test and share mods without an account. The account is only for putting them on this site, where hosts find them.
Pages
- The Mod Studio: the mod maker, step by step
- The .dmod format: every file and field (to make mods outside the game too)
- Scripting (Lua): the server's and the player's API, with examples
- Running a mod on a server: host.dr2.site, or your own server
Rules for uploads
- Your own work, or work you have permission to use (say where it is from in the description).
- Nothing hateful, sexual or meant to hurt players or their computers. Scripts only run inside the game's sandbox; trying to escape it gets the account banned.
- A new version of your mod: the same id, a higher version (1.0.0 → 1.0.1 or 1.1.0).