views
114
likes
2

Comments

What do you think?
No comments yet.

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:

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:

#programminglanguage #script #lua #objectoriented #procedurial



all-ages
Nothing has been posted to this project page yet. Check back later!