esolang

smotslang

Crumble, climb, dash, spike and spring. A cell machine whose words come from a corner of Celeste modding.

Turing complete: unknown · ●○○ easy · esolangs.org

Tested with 2 known programs · Test method

Run it

Expected: Hello, World!

The idea

smotslang is built around words from smots gaming, a niche corner of the community that mods the indie game Celeste. Under the words sits a plain machine with numbered memory cells, one of them current. You store a number with crumble, move to another cell with dash, print with retry and loop with jump markers, which spike and spring aim at.

Read the story

The specification writes its name in lower case. Its official interpreter is in Node.js.

The machine

WordDoes
crumble vStore v in the current cell
climb fallAdd or subtract 1
dash v wind vMake cell v current; copy the current cell to cell v
debug reloadPrint numbers; print characters
retry runPrint the current cell; the same with a line feed
jump nSet marker n
spike nIf the cell is 0, skip ahead to jump n
trigspike v nIf the cell is not v, skip ahead to jump n
spring nIf the cell is not 0, go back to marker n
spinnerSet the cell to 1 one time in three, else 0
smots5Halt

A value is ^72 for a number, 'H for a character, $^2 for the cell at 2 and @madeline for a number read from the input. A word that starts with -- opens a comment, and the next word with -- in it closes it. The specification does not explain these four values; the meanings used are the ones its examples need. campaign, which runs another file, stops with an error.

Example

The Hello World switches to characters with reload and prints one crumble at a time.

The Hello World switches to characters with reload and prints one crumble at a time.

The truth machine from the official examples. On 0 spike 8 skips the loop and prints once. On 1 spring 7 keeps going back to marker 7.

Expected: 0

A countdown, with spring going back while the cell is not 0.

Expected: 3 2 1

The coin flip calls spinner twice until the two cells differ, which gives fair odds. The spinner draws from a fixed seed so that a run replays, and the coin flip always lands on Heads.

Further

Cell-based

Write your own in Run Convert a program from smotslang

Implementation

JavaScript interpreter, source and command line

A JavaScript interpreter, used in the browser and on the command line. Id: smotslang.

Command line

shib run smotslang -e ' -- by: nilrem --
 crumble @madeline
 spike 8
     jump 7
         run
     spring 7
 jump 8
 run' --input '0'
shib manual smotslang

Source

Module
langs/wiki/ports.js
Interpreter
langs/wiki/smotslang.js

Docs: Kernel instructions · The .shib format · Command line · Adding a language

Source esolangs.org (CC0) · Edit on esolangs.org