Data commit

This commit is contained in:
Ingy döt Net 2023-07-01 11:58:00 -04:00
parent 7387c8f97b
commit cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions

View file

@ -0,0 +1,11 @@
if (condition)
// Do thing, DM uses indentation for control flow.
if (condition)
// Do thing
else if (condition)
// Do thing
else
// Do thing

View file

@ -0,0 +1,2 @@
// x will be 1 if condition is a true value, 2 otherwise.
var/x = condition ? 1 : 2

View file

@ -0,0 +1,14 @@
switch (value)
if (0)
// Do thing if zero
// DM does not have fall through of switch cases, so explicit break is not required.
if (1, 2, 3)
// Multiple values can be allowed by using commas
if (10 to 20)
// Ranges are also allowed.
// Ranges include the bounds (10 and 20 here),
// and are checked in order if there is potential for overlap.
else
// Fallback if nothing was matched.