Sx4.txt: S+4 : Sacas Plus, iteration 4 
Documentation on the S+4 implementation
to date (28 April, 2000).
---:

Format:

For an example o fa S+ Correct Format (S+CF) file, 
see "sex2.cas" (S+ EXperiment Constricted nASic 
( .cas is a throughback to the M7 days)).

The S+CF has a few limitations, the most important
is that whitespace is necessary and important,
too little or too much will really mess things up. 

End the file with 'e' on a line by itself, followed by
'-' on a line by itself (yes, you can cheat and use
stuff after the '-'. But don't make it a habit elsewhere.

---:

Commands:

Termination:

'e' 
:End of Program

'-'
:End of File

both of these are necessary!
(well, this is loosely inforced in the 
current implementation, but please use them,
it will make me happy).

---: for the Allegro/V1 version:
Graphics display 

'r'
:Render, currently, this stamps a sprite onto the
screen.
---: for the console version:

Burst mode pause command

'r'
:rest. This causes burst mode to pause, returning
control to the driver program. Without this, the
S+ engine would execute forever without ever stopping
to let the external program do anything. 

In the future a limited-iteration burst, and a step 
mode will be added. 


Simple Maths Stuff: 
(The 'A' in ALU)

[var] is a one-character
name of the variable (think of 'x' and 'y')

[val] is an integer (like 180)

'l'
:l [var] [val]
Let the var be the val, where var is a one-character
name of the variable (think of 'x' and 'y'), and 
val is an integer (like '180')

'a'
:add [var] [val]
Adds the value to the variable.

's'
:substract

---:

Note that the 'r' command only pauses the engine so that the
controlling program can read 'x', 'y', and do the rendering.

This means that this engine is actually a lot more flexible and
general purpose... you could use different var. names, more
var. names, and do more exciting stuff... 

And now, they are even Logic commands (making this an ALU!
Yah!), read on below for more information

---:

I call this S+, short for SACAS Plus, 
but really, it's not as flexible as SACAS yet, 
this is like the compiled file here,
there is no preprocessor as yet, although the loader
loads the script into native C++ constructs (rather
than nondescript binary format).

---:

New Branching, Labeling, Comparison commands
(Logic section)

'c' [var] [val]
:Compare [var] and [val],
setting the Boolen Variables!

Boolean Variables:

'<' 
: left side was less than right side ( [var] < [val] )
'>'
: left side was greater than right side.
'='
: both were equal.

Branching:

'b' [Boolean Variable] [Atomic Label Number]
'n' [Boolean Variable] [Atomic Label Number]
:'b' branches if true, 'n' branches if false.
(see "sex2.cas")

'o' [val]
: Objective Label (Sacas throwback), 
[val] is the Atomic Label Number. 

---;

Things to come: 

A preprocessor that uses label names and 
translates (strips, assigns atomic numbers)
more human readable formats 
to S+ Correct Format (what the top part
of this file is). 

Coprocessor stuff (or, co-unit stuff) so that I 
can extend the parser at runtime by calling attach().
(don't worry if that makes no sense... all things 
in time...).

---:

Hails: 

	Master Chip
	Sir Nelish Batel
	Sig9 - aka: RCS
	Lord Twoodington
	"ROMAN"
	"Gohanz"

---:

S+ Demonstration file, by Keinall "Granitor" Caddle, 
aka K31, 27 April, 2000. No warranty is given, 
use at your own risk.

---] K31

