Comments
Neil is an extension language to Lua.
Where Lua is a very extremely open language with a lot of freedom, Neil is far more restrictive, but therefore easier to debug and also more focused on OOP support. Especially for larger projects this can really be a benefit (since typos in variable names and function names can haunt you in Lua).
A few specifications
Procedurial. Everything must live within functions
Variable declaration obligation. This prevents issues with typos in variables giving you bugs very extremely hard to fix.
Case insensitive. So "Print", "print", "PRINT" and "PrInT" will all be handled the same
Very limited macro support
Conditional compiling support
Class support
Property support
Switch/case support
Neil can be interfaced with Lua and vice versa
Let's not break with traditions. Here is Hello World:
Init
Print("Hello World!")
End
A nice example to show you:
Int F(int n)
If n<0
return 0
ElseIf n==0
return 1
Else
Return F(n-1)*n
End
End
Init
For i=1,10
PrintF("!%d = %d\n",i,F(i))
End
End
// Can you see what this does?
Sites:
Github (Language itself. Neil.lua contains the entire language)
Starting guide (also on Github)
Note
I will NOT host Neil itself on Game Jolt. That is rather because it's easier for me to maintain on Github only. If you have git yourself you can make sure by pulling the repository every now and then, and if you are not sure how to use git you can download Neil manually from Github also (since it's only one file, no real problem, right?)
Games written (or to be written) in Neil:
The Fairy Tale REVAMPED (not the current version, but the next version will be)
Sixty-Three Fires of Lung (Planned. No promises yet)
Star Story II (Planned. No promises yet. Not even a page yet)
#programminglanguage #script #lua #objectoriented #procedurial