The Mod Studio
The Mod Studio is this site's mod maker: modsc.dr2.site/studio. It works in any computer's browser (a mouse and a keyboard help; a big screen helps more). The game's Modding item opens it.
Your mods are kept in this browser as you go (the top right says Saved in this browser). Export saves a mod as a .dmod file: to keep a copy, move it to another computer or share it. Open a .dmod file (or drop one on the page) brings one back, yours or someone else's.
Starting
The first page lists your mods and the templates a new mod starts from:
| Template | What you get |
|---|---|
| Empty | Only the game options and empty rules |
| A map | A map with ground, spawns, rings and the exit |
| Race to the exit | A map and rules: the first survivor through the exit wins |
| Hot potato | Rules and a HUD: pass the potato before it blows up (the host sets the fuse) |
| Ring rush | Rules: a ring every 5 seconds, the most rings wins |
| Objects | Coins that bob and give rings, spikes that hurt: objects with events |
| Character skin | Tails with stats of your own, a double jump in Lua, and a skin started from the game's pictures |
The workspace
Like GameMaker: the assets at the left (folders, a search box, + to make or import anything, a right click to rename, duplicate or delete), the open things in tabs, the selected thing's settings at the right (the inspector), and Problems / Output under them. Drag the borders between them to resize; the arrow folds the output away.
Drop .png, .ogg, .lua or .dmod files anywhere on the Studio to import them (on the Sprites or Pictures folder: as that kind).
The bar at the top:
| Button | |
|---|---|
| Check | The site's own checks, as when publishing. Problems are listed under the editor: a click opens the thing at fault |
| Run (F5) | Plays the mod in the web game, in a new tab: one of its maps, or a game map, as the character you pick. The rules, the objects and the characters' moves run there too, as if you were alone on a server (the exit opens in the last minute; when the round ends it starts again). Run again: the same tab plays the new version |
| Export | The .dmod file |
| Publish | Puts it on this site (modders, see below) |
Game options
The mod's name, id (its address on the site: a-z, 0-9, _, -), version (raise it for every
upload), author and description; whether the vote shows only its maps; whether bots play; the
settings for hosts (a number, on/off, a text or a choice: the scripts read them as
mod.config.<key>); its picture on the site; a read-me.
Maps (the room editor)
The tools at the left of the map (keys in brackets):
| Tool | |
|---|---|
| Select (V) | Click to select, drag to move, the white corner resizes; Shift adds to the selection; drag on empty space selects a box; Del deletes, Ctrl+C / Ctrl+V copy, the arrows nudge |
| Tile (B) | Paint the tile chosen in the palette (right). Shift+drag fills a box; the right button erases |
| Erase (E) | Remove tiles |
| Solid (R) | Drag a solid block: ground, walls |
| Platform (P) | Drag a one-way platform |
| Slope (S) | Drag a slope; the way you drag sets the high side |
| Object (O) | Place the object chosen at the right: spawns, rings, the exit (where the big ring can appear), springs, and the mod's own objects |
The wheel zooms, the middle button (or Space + drag) pans; ↶ ↷ undo and redo (Ctrl+Z / Ctrl+Y). Layers (right) show or hide the objects, the tiles' collision, the tiles, the pictures, the background and the grid. Each tile of the tileset can be solid, a platform or a slope: tick Edit each tile's collision and click the tiles. The map sets its name, description, size, round time, music, background (a colour, a picture of the mod or one of the game's) and the picture shown in the vote. Test plays it at once.
A map needs a survivor spawn, an EXE spawn and an exit. The big ring stands on the exit's spot (put it on the ground, or players must jump into it). The map's left and right edges are walls; a player who falls off the bottom comes back at the nearest spawn, hurt.
Scripts
Game rules (server.lua) is the game mode, run by the server. Screen (client.lua) is
each player's HUD. + makes a Lua module for require. The editor completes the API as you
type (Ctrl+Space), marks syntax errors in red as you type, and the panel at the right lists every
function and hook: a click puts it in. See Scripting.
Objects
Coins, traps, enemies, anything of your own: + on Objects. An object has a sprite, a
collision box (drag over the picture, or type it), front (drawn over the players), whether
players pass through it or it is solid (they stand on it and bump into it; a moving one carries
them) or a platform (they stand on its top), and the variables each one starts with. Its events are on the left: Create, Step (60 times a
second), Touch (a player came onto it), Leave, Destroy. A click on one goes to it in the code, or
adds it. Place objects in maps with the Object tool, or make them from the rules with
game.spawn("coin", x, y). See Objects.
Characters and skins
+ on Characters & skins: the character it is made from (its moves), its name, its stats
(speed, acceleration, jump, gravity, damage taken: 1 is the game's) and hit points. Every action
of that character is listed with the game's animation beside yours: Import strip (the frames
left to right), Frame files (one picture a frame), or Draw (it starts from the game's
picture). Give it moves writes its own moves in Lua (characters/<name>.lua): a double jump, a
dash, a glide, with animations of its own that everyone sees (see
its own moves). Test this character plays as it.
Sprites and the pixel editor
A sprite is a strip of frames. Animation shows it playing: set the frames, the origin (a click on the picture, or the buttons) and the speed. Draw opens the pixel editor: pencil (B), eraser (E), fill (G), colour picker (I), line (L), rectangle (R, Shift: filled), move (M); mirror (X), onion skin (O), the grid; frames added, duplicated, deleted and moved below; the frames' size; undo / redo. The right button erases. It saves as you draw.
A sprite named like one of the game's (spr_ring) is drawn instead of it: a skin.
Pictures, sounds, the lobby
Pictures are for maps (tilesets, backgrounds, art) and the mod's picture. A sound named like one
of the game's (snd_ring, mus_hill) plays instead of it; any sound can be a map's music. The
lobby sets what players see while they wait: a title and text (with the colour codes), a picture
and music, with a preview.
Publishing
Make an account and apply to be a modder. Once an administrator accepts you, log in (top right of the Studio) and press Publish: it checks the mod and puts it on the site, where server hosts pick it. A new version: the same id, a higher version.