Sexy Scripting Language Wiki
An s-expression scripting language for highly demanding video games
Status: Beta
Brought to you by:
theabstraction
Use (function ...) to declare a function.
Functions take inputs and maps them to outputs using a body of logic. This is specified thus:
(function (<input_type1> <input_name1>) .... (<input_typeN> <input_nameN>) -> (<output_type1> <output_name1>) .... (<output_typeN> <output_nameN>) : <body> )
A function that specifies no input and maps to a single output value is called a get-accessor
Example:
(function PI -> (Float64 valueOfPi): (valueOfPi = 3.14159) )
Currently a function definition that specifies no output still requires a mapping symbol (->), and the
programmer should be sure to use blank space to separate this from the body indicator symbol (:).
Example:
(function RingBell (Float64 hz)(Float64 decibels)-> : (Sys.Native.Audio.Beep hz decibels) )