Extracting TorqueScript
by Helk · in Torque Game Engine · 03/20/2006 (7:51 am) · 7 replies
Hello everyone.
Before I get started with this task I was wondering if anyone could share any knowledge that could assist me in extracting and implementing the TorqueScript language and console in another application, as well as if any veterans have any pointers on good places to look, so far I've been looking at the console\ folder and getting a handle on things. I've worked with LUA before but I really dislike it's syntax and I much prefer torquescript for various reasons; enough so that I think this rather large task would benefit future projects of mine.
Thanks in advance.
Before I get started with this task I was wondering if anyone could share any knowledge that could assist me in extracting and implementing the TorqueScript language and console in another application, as well as if any veterans have any pointers on good places to look, so far I've been looking at the console\ folder and getting a handle on things. I've worked with LUA before but I really dislike it's syntax and I much prefer torquescript for various reasons; enough so that I think this rather large task would benefit future projects of mine.
Thanks in advance.
About the author
#2
03/20/2006 (8:55 am)
That's my initial thought too.
#3
03/20/2006 (10:12 am)
Yeah, I already contacted GG about that becuase I had the same concern; All the code is mine to use any way I want so long as its not exposed to other people not having a proper TGE licence. (which will not be happening so in short, yes it's fine)
#4
03/22/2006 (6:41 am)
No input from you guys other than that?
#5
03/22/2006 (7:08 am)
Well I don't think its going to be easy no matter where you start... This is a pretty large task.
#6
Javascript is somewhat close to TorqueScript -- close enough that I use the Javascript syntax coloring extension in my text editor to edit TorqueScript. (other things like inheritance are handled differently, of course).
In any case, if you're just looking for a nice embedded script engine, it would probably be a lot easier to use one of these than trying to extract TorqueScript to something that didn't use the rest of the engine.
http://www.mozilla.org/js/spidermonkey/
http://www.mozilla.org/rhino/
03/22/2006 (7:40 am)
If you just like the syntax of TorqueScript, but don't need it to be compatible, etc..., I'd look at using one of Mozilla's javascript engines instead. I've embedded both their SpiderMonkey C-based engine and the Rhino Java-based engines in applications, and found it very easy to both use and extend.Javascript is somewhat close to TorqueScript -- close enough that I use the Javascript syntax coloring extension in my text editor to edit TorqueScript. (other things like inheritance are handled differently, of course).
In any case, if you're just looking for a nice embedded script engine, it would probably be a lot easier to use one of these than trying to extract TorqueScript to something that didn't use the rest of the engine.
http://www.mozilla.org/js/spidermonkey/
http://www.mozilla.org/rhino/
#7
Wouldn't it be easier to use Lua instead ? Lua was created to be used as a scripting language for any system, so it's designed to be easy to couple with an existing system.
03/22/2006 (11:18 am)
TorqueScript's implementation isn't really easy to copy, it's all based on the console which is also the "heart" of the engine. Wouldn't it be easier to use Lua instead ? Lua was created to be used as a scripting language for any system, so it's designed to be easy to couple with an existing system.
Associate Stefan Beffy Moises