What is Gem?
Gem is a scripting language, written in JustBasic.
What's its Syntax?
Gem's syntax is highly simple.
Code: Select all
1 Write Hello
2 Write World
3 NewLine()
4 Input() -> %1
5 Cls()
6 Exit()
Code: Select all
;Greeter
1 Write Hello!
2 Write What
3 Write is
4 Write your
5 Write name?
6 NewLine()
7 Input() -> %1
8 If %1 == NULL GOTO 20
8 Write Ok,
9 Write goodbye,
10 Write %1
11 NewLine()
12 Input() -> %1
13 Exit()
;Example of a 'if' block, called from line 8
20 Write You
21 Write did
22 Write not
23 Write give
24 Write a
25 Write valid
26 Write name!
27 NewLine()
28 Input() -> %1
29 GoTo 1
What is Gem For?
I developed Gem in preparation for an experiment in artificial intelligence. The AI shall be able to dynamically alter its behavior via the execution of Gem scripts.
Yet Gem can be applied to far more scenarios than just AI. Gem could be used for app-extensibility (for example, scripts to apply effects to an image), and, perhaps, multi-threaded execution (a JB file executes a TKN which runs Gem scripts simultaneously).