X3-Reunion did it (I made a thread here: http://star-made.org/content/computer-blocks-which-support-custom-code-pre-selected-functions )
Basically it had \"input fields\" for variables inside text (comments).
You use an editor to fill these fields. On save, the text(-id) and fields are mapped to \"returnValue = functionX, variable1, variable2\" and executed by a parser (imagine java-bytecode and some functions in C++)
It is newbe-friendly, because everything is not hirachically sorted but also has no programming stuff (except variables).
I am not too much against LUA, but it has it\'s downsides - here are three examples:
- Indexing starts with 1 (personally don\'t like, because it is different from everything else - Java, C++, PHP, JavaScript, ...)
- \"text\"..\" concatenation\"..\" multiple\"..\" times\" cause the system to update the hash=string table 4 times - in runtime. That is especially bad with automatically generated names.
- Return values can have anything - from boolean to integer, etc. Someone changes his code and you notice it first if you use your function for a ship with the name \"_WITH_UNDERSCORES_\" - your stuff crashes while it worked x days before with the older version.