Game Development Community

dev|Pro Game Development Curriculum

Torsion Updated!

by Tom Spilman · 03/21/2006 (12:48 pm) · 35 comments

www.sickheadgames.com/images/shbug_03.pngFirst off I'm at the GDC this week. If anyone wants to meet up just drop me a name and phone number to tom AT sickheadgames DOT com and I'll give you a call back. I hope to spend some time with the GG guys talking Torsion and checking out all the cool new stuff they're about to unleash upon us. =)









www.sickheadgames.com/images/torsion_r_logo500.jpg

So aside from contract work Torsion has been my primary focus of late. Today I released a new version that has a significant amount of improvements. I think this will be the final alpha release. The next release will be a beta and be 100% feature complete.

www.sickheadgames.com/stuff/garagegamesimages/projectconfig_t.png

A few notable changes:
  • New project setting allows ignoring of select mod folders in both the project tree and for code completion.
  • Enabled code completion for fields within object and datablock declarations.
  • Script compiler errors are highlighted in the output window and they are double clickable.
  • New error display within output window for spotting errors quickly.
  • Added visibility toggle of left and bottom panes in view menu.
  • Added preferences dialog exposing all customizable IDE settings.
  • New optional pre-compile dumps the syntax errors of modified scripts into output window before execution.
PrecompilerIMO the coolest thing in the new release is the script precompiler.

www.sickheadgames.com/stuff/garagegamesimages/precompile.png

When enabled it will compile any changed scripts before you launch your game. If you have any syntax errors they will be caught and reported in the output window. It works by calling your game executable with a special script file which just compiles a list of scripts. Since it uses your Torque executable it's always accurate and never misses or reports false errors. Say goodbye to alot of wasted time with this one feature.

The down side is that it assumes your Torque executable will run the script passed to it. If you have disabled this feature in your executable it won't work. I've added the ability to toggle it off per config to deal with that case.


www.sickheadgames.com/stuff/garagegamesimages/codebrowser_t.pngCode Browser
The code browser has started to get a face lift, but it's not finished for this release. I've started to add filtering for different classes of identifier, but the mix isn't final yet. It now also shows the base class/datablock when you expand an object which is pretty handy. When you double click on an item it will take you to the script and line that identifier is declared in or will show you a list of locations to choose from.

I could use some feedback on this area of Torsion. There is a ton of data to display here and it's been challenging finding a way to display it all. I'm starting to think i need to do something different that what is normally seen in most IDEs.




www.sickheadgames.com/stuff/garagegamesimages/completion_t.pngCode Completion
This release has my third and final refactor of the code completion scanner engine. It took me a couple of tries before i got the design right as when i started the Torsion project i was pretty much a TorqueScript neophyte. Aside from the internal changes and performance improvements i added dot completion for the special %this local. I didn't get time on this pass, but it's all ready now to finish off all the other typical code completion features. I'll be on this right after GDC.





Preferences
Finally i've begun the process of exposing the preferences stored in the xml file to the IDE. All the coloring stuff is there as well as a few other toggles including tab size and type, disabling code folding, and code completion. There will be more options added now that the framework is in place to easily edit them. If you have a pet option go ahead and log it into our bug tracker.

Well... gotta get some lunch and rub elbows with industry folk. =)


Download Torsion
v1.0.544 Alpha

About the author

Tom is a programmer and co-owner of Sickhead Games, LLC.

Page«First 1 2 Next»
#21
03/22/2006 (11:47 am)
I always hear how awesome this game is, it's just that i don't know how to play.. :(
#22
03/22/2006 (7:31 pm)
Doh. I was hoping you'd have some way to make doing it actually worthwhile... Oh well. =)
#23
03/22/2006 (9:17 pm)
@Mark:
I'm doing most of that, no boost stuff yet but that sounds interesting. #define "constants" are great for my little integer based "message system". Another thing is being able to #ifdef DEMO //skip some code...

@Tom:
If you are considering adding this feature I will really appreciate it! But writing a preprocessor is no fun so incorporating GCC may be the easiest way. What I do is run a batch file over my scripts one at a time for now, with a command like this :
gcc -E -P -x c %1 -o %~p1%~n1
And pass the full filename to this batch script. That will only preprocesses the source file, named with an extension .h.cs and outputs a .cs file of the same filename in that directory. It's cheesy but it works for me. However it can be tedious when I edit lots of files or frequently change one file...

Edit: Sorry to bug you but I tried the current alpha of Torsion and I got an error, "Loader Error - The procedure entry point GetProcessId could not be located in the dynamic link library KERNEL32.dll". It could just be my system since I installed lots of stuff over the past few weeks...
#24
03/22/2006 (9:34 pm)
@Joe and Mike Lilligreen - I found this issue .... GetProcesssId is a feature added to WinXP Service Pack 1. If you want to get Torsion working right away you'll have to update, but i need to remove this dependency as i don't want to screw Win 9x people. Thanks for reporting this guys.

@Joe - Well... i thought i could maybe add an option in the project preferences to execute a user specified command before executing any game code. This way you could launch GCC to do whatever you like.
#25
03/23/2006 (3:39 pm)
Awesome Tom, that way will be more flexible. If you end up doing this would it be too much to ask for a way to pass the filename, directory path, etc in with that command?
#26
03/31/2006 (5:34 am)
can torsion do the same as visual basic?.. i mean.. can i do ALL my scripting in Torsion and what about compiling.. don
#27
04/01/2006 (6:23 pm)
@Bardur - Torsion is a complete environment for editing and debugging TorqueScript for use with any of the Torque engines. It does not have anything to with Visual Basic and it does not compile C++ code.
#28
04/02/2006 (4:06 am)
Ok.. thanks Tom... i kinda figured that out yesterday... after posting hehehe

but thanks for replying
#29
04/19/2006 (6:05 pm)
Hey Tom,

The new torsion doesn't let me type in a question mark. I.e., try to type '?' in any script in torsion...
It worked in the old version, what happened??? :^)
#30
04/19/2006 (7:14 pm)
@Shai - I either subconsciously decided that question marks are unnecessary or that was just a stupid bug on my part. =)

It's fixed and will be in the next build.
#31
06/24/2006 (8:34 pm)
I love Torsion! Seriously, we're getting married. We're in love and we're not going to let anybody get in our way!

So we're using Torque with Torsion (not to be confused with Certs w/ Retsyn) in my Game Dev class at BCC (see sporadic notes of nominal quality at http://riki.thegameaddicts.net). There was a few of us who... don't read instructions. So there were problems in setup. But once it's up and running Torsion is a dream to use! I was editing most of the things in notepad before and it's just not cut out for the job. After using Torsion I don't get confused about which file I'm in anymore which is SOOOO nice.

One request, though (and somebody chime in if you agree or disagree), can you make the window scroll effective on mouse-over? Currently you have to click in the window that you want to scroll, and it's a bit annoying. It's a small thing, but it can make Torsion that much friendlier. Is "friendlier" a word?

Thanks for the quality product.

n8
#32
01/03/2007 (3:47 pm)
does it have spelling check? i am using it, but i hate when "function" does not convert to "Function" or when "imagemap" is not the same to "ImageMap" :(

it is been a great IDE!

Congrats to the developers!

matt.
#33
01/03/2007 (4:06 pm)
@Matt - No spellcheck yet... i'll look at that in 2.0.
#34
02/02/2007 (12:08 pm)
First let me say I love Torsion! I bought it as soon as it came out. I am having a problem with the pre-compile step though.

I intentionally created a syntax error in a script to check out, and it works as expected in TGE 1.5. In the Shader / Advance EA Engine however it just blows right past the syntax errors and starts the game.

In TSE, however, Main.cs calls an init.cs that contains the exec calls. (IMO a better way to keep track of your scripts).

I even placed the syntax error as high as the >> GameName/main.cs and pre-compile never fails.
#35
02/02/2007 (12:17 pm)
Tom says:
This is a bug in TSE/TGEA...

http://www.garagegames.com/mg/forums/result.thread.php?qt=56841

This should appear in the next TGEA release, but until then if you make that fix then syntax errors will reappear in Torsion.

PS Tom is my hero!
Page«First 1 2 Next»