Untitled

From Esolang
Jump to navigation Jump to search

Untitled is a 2D language created by CreeperBomb. Code is comprised of cells containing one character each & is done by points.

Names

Untitled also goes by "Only Name", and during its design process was called "Final Name". "Untitled" is the main title, however, so it will be used in this wiki instead of Only Name. "Final Name" is incorrect.

Points

At the start of the program, points are created. Points have a direction and two integer values (starting at 0) used to form a rational number via a fraction. They travel one character at a time. Once all points are deleted, the program ends. If two points colide (land on the same character), then they merge into one point. This point has the direction of the smaller point and, except in certain cases, the value of the larger.

General commands

><ʌv can be used to spawn a point in the respective direction. ^ can be used in place of ʌ if the programmer desires. * deletes any point that goes on it.

/ & \ can be used to reflect the direction of a point. ASCII box drawing characters can also be used: if the character connects in the direction a point is coming in, the point will exit on the other arm of character. For example, └< results in a point going up. If the character doesn't connect in the direction of the point (like in >│), the point is stopped. If the character tells the point to go in multiple directions (like in >┤), the point is duplicated for each direction.

By using a double-lined ASCII box drawing character, it will only allow just-collided points through.

Computational commands

i is used to increment a point, & d to decrement. You can also directly input a number by typing its digits without break. For example, >54 results with a point with 54, and 4 5< results with a point with 4. _ sets the denominator of a point to 1, and ¯ sets the numerator of a point to 1. Note that points always simplify, so if you set a point to 4/2, it is actually set to 2/1, which can change how _ & ¯ act.

+-÷x% change how points on top of them get their value during a colision. The bigger number always comes before the smaller number, except for ÷. + adds, - subtracts, x multiplies, ÷ divides, & % mods.

Other commands

The commands .,:; are used for I/O. . prints a number, : prints a Unicode character, , requests numerical input, & ; requests a Unicode character and converts it into a number. Multiple characters can be put with : & ; in which text is treated like base 4,294,967,296 (max amount of characters Unicode-32 can have).

You can also create gotos by writing a nonreserved lowercase, which will cause a point to go to the uppercase counterpart (choosing one at random if there's multiple). $ is used to send the point back. Gotos can be nested.

Another goto method is using ' & ". ' sends the point to the nearest " (measured in chessboard distance). If there's a tie, it will randomly pick one of the tiers to send the point to. Unlike with letter gotos, the randomness for ' is global.

Table of Characters

Character(s) Description
> < ʌ ^ v Creates a point in the direction shown
* Deletes any point that crosses over it
/ \ Reflect the direction of the point
Light box-drawing characters Guides points through like a tube, duplicates points on path divergence, & stops any points coming in from the side
Double box-drawing characters Only allows points that have just collided with each other
i Increment the point's value
d Decement the point's value
0-9 Set point's value to number provided. If the point crosses numbers consecutively, they will all be treated as a single number
+ Adds colliding points together
- Subtracts colliding points
÷ Divides colliding points
x Multiplies colliding points
% Mods colliding points
. Output crossing point's value
: Output crossing point's value as a Unicode character or as multiple unicode characters
, Set crossing point's value to number from input
; Set crossing point's value to Unicode value(s) of input
' Send point to nearest double-quote, measured in chessboard distance, choosing a random one upon a tie
" See '
$ Return from last goto
_ Set point's denominator to 1
¯ Set point's numerator to 1
Non-reserved lowercase Go to corresponding uppercase character. Randomize which one to go to if there are multiple
Non-reserved uppercase See non-reserved lowercase

Example programs

Cat program:

 >;:*

Hello world:

 >72:101:108::111:32:119:111:114:108:100:*

Truth machine:

   v  v
   3  1
 >,x"d-ii.*
   ╚' ╚".'