esolang

Cscalls

A program reads like the voice chat of a CS:GO round.

nmcassa, 2022 · Turing complete: unknown · ●○○ easy · esolangs.org

Tested with 3 known programs · Test method

Run it

Expected: Hello World!

The idea

nmcassa made Cscalls in 2022 out of CS:GO callouts. Every line is something a player might shout. One at Hello World! pushes a string, PEEK prints it, and Why is no one A jumps to the label HELP A.

Read the story

Memory is a stack of strings with a pointer into it, and a hand, which holds one value the way Tetris holds a piece. The only test compares the item at the pointer with the hand and jumps to a line number.

The machine

LineDoes
One at XPush X and point at it
team?Push a line of input and point at it
PEEKPrint the item at the pointer
GRAB AWP / I'm loaded I can dropMove the pointer down or up
Tagged N timesPoint at item N
hacking istg pls reportRemove the item at the pointer
What skin is that?Copy the item at the pointer into the hand
Drop me AK / YO INSPECTPush the hand; print it
WHERES MY TEAMPrint the whole stack
HELP X / Why is no one XA label; jump to it
save pls i have $NJump to line N if the item at the pointer equals the hand

Lines count from 0, which the truth machine needs. The interpreter is in Python, so each print ends with a line feed, as Python's print does.

Example

The truth machine keeps 0 in the hand and compares the input with it.
Expected: cat

The truth machine keeps 0 in the hand and compares the input with it. On 0 it jumps to line 6, prints and ends. On 1 it moves the pointer down to the 1 it pushed, holds that, and loops on PEEK forever.

Expected: 0

Patterns it teaches

Further

Pseudonatural

Stack-based

Write your own in Run Convert a program from Cscalls

Implementation

JavaScript interpreter, source and command line

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

Command line

shib run cscalls -e 'team?
PEEK' --input 'cat'
shib manual cscalls

Source

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

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

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