Timeline for How does Lua work as a scripting language in games?
Current License: CC BY-SA 3.0
11 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Apr 21, 2014 at 23:53 | comment | added | Mason Wheeler | Osterhout's Dichotomy should be taken with a grain of salt, seeing as how he set it up specifically to promote a scripting language he had written that fits the parameters he set out quite well. But most scripting languages these days have some sort of JIT, which contradicts the third point, and a lot of scripting for serious games takes place in languages that do not match the first two points of the Dichotomy. UnrealScript comes to mind, and you can bet that the folks building games in it would not want to have to make do with dynamic typing! | |
Apr 21, 2014 at 17:26 | comment | added | Alec Teal | @OlegV.Volkov I forgot about the javatards.... In the real world :P But yeah you're right "compiled" occurs in a lot of places, even SQLite "compiles" queries to a VM language. Now imagine we have two words, A is what GCC does, B is what the Lua interpreter (sorry compiler :P) does. Quite clearly A is not B (in python terms) even if A==B in terms of letters. Does that help? | |
Apr 21, 2014 at 17:20 | history | edited | Gurgadurgen | CC BY-SA 3.0 |
added 1153 characters in body
|
Apr 21, 2014 at 17:07 | comment | added | Gurgadurgen | Generally speaking, it is common to assume that a language being used as a scripting language is interpreted, but let me expand on my answer here, so this issue can be clarified and resolved. | |
Apr 21, 2014 at 16:30 | comment | added | Oleg V. Volkov | @AlecTeal, uh, go ahead, call Java an interpreted language then. It is called "compiled to bytecode" everywhere. | |
Apr 21, 2014 at 12:49 | comment | added | Alec Teal | First part is iffy, I'm tempted to downvote. He is kind of right in that it is ultimately interpreted and @OlegV.Volkov JIT compiling doesn't make something compiled. Compiling is defined by compile time, which Lua has, Lua byte-code does not (JIT or no JIT). Lets not get our term muddled. | |
Apr 21, 2014 at 10:38 | comment | added | Oleg V. Volkov | Even regular Lua is completely compiled to bytecode, JIT compiler can even produce native binary. So no, Lua is not interpreted. | |
Apr 21, 2014 at 2:35 | comment | added | glampert | Fair enough, your definition is more inline with Wikipedia: "A scripting language or script language is a programming language that supports scripts, programs written for a special run-time environment that can interpret (rather than compile)...", never mind my comment then. | |
Apr 21, 2014 at 2:32 | comment | added | Gurgadurgen | I'd disagree with your definition of "scripting language." There are languages with dual uses (such as Lua, or C#) which are relatively commonly used in their compiled form, rather than the script form (or vice versa, as is the case with C#). When a language is used as a scripting language, it is strictly defined as a language that is interpreted, and not compiled. | |
Apr 21, 2014 at 2:26 | comment | added | glampert | I'd disagree with you on the first line where you wrote "scripting languages are not compiled". Lua is in fact compiled into intermediate bytecode prior to execution by a JIT compiler. Some are of course interpreted line-by-line, but not all. | |
Apr 21, 2014 at 2:21 | history | answered | Gurgadurgen | CC BY-SA 3.0 |