Game Development Community

Torque IDE

by Sam Bacsa · in Torque Game Engine · 07/18/2005 (5:12 am) · 75 replies

So I bought Torque a while back, then bought TSE, and I've found myself growing increasingly frustrated due to the severe lack of GUI available in Torque.

I've set out to design an IDE which I will gladly make available to everyone (free of charge, obviously) if people are interested. I am posting this here because I'd like some feedback from you guys ... as in, what would you like to see in an IDE? Would an IDE make your lives easier?

Here are some screenshots that I whipped together really fast, of what I have currently. Click on the thumbnails for a larger view.

www.imgspace.net/thumb.php/Z42db96e8e4fd4.jpg
This is the main interface. You can see the project explorer on the left, a rudimentary toolbar at the top, open file listing at the bottom, and the editor in the center. The editor is currently displaying an on-demand helper tip, which can be obtained whenever you press CTRL+SHIFT+SPACE, just like in visual studio. It will display help for the current function, so long as you're in its parentheses or right next to them.



www.imgspace.net/thumb.php/R42db96e913073.jpg
Identifier tokens can also be moused-over to get brief information in a nice tooltip.



www.imgspace.net/thumb.php/E42db96e91f3a3.jpg
You can right-click on any identifier and have the editor take you straight to the definition of the function (so long as it's user-defined. Built-in functions can't be jumped to, of course).



www.imgspace.net/thumb.php/L42db96e92b709.jpg
Here's a view of the project explorer and the file properties dialog (which can be obtained by right-clicking on a file and selecting properties). The project system in the IDE is all "virtual". In other words, directories aren't really there, and files can take on different names from what they really are. You can even have two files of the same name if you wanted to. The paths are also all relative allow you to easily ZIP up your project definitions and distribute them if necessary, without breaking the links. Files can be dragged & dropped into individual folders. Deleting a file from the list won't delete it completely.



www.imgspace.net/thumb.php/T42db9778bc030.jpg
Custom functions have their own special tooltips on mouseover and quickinfo.




www.imgspace.net/thumb.php/R42db9aefcb7bb.jpg
There is also a useful export feature for exporting formatted source code to either RTF or HTML.




www.imgspace.net/thumb.php/M42db9aefdf024.jpg
Here's an exported block of code formatted to HTML.



Now that you've seen most of the features of this IDE, is there anything you'd like to see specifically? Please let me know and I'll do my best to code it in.

I'm already planning to have auto-complete for built-in events, interfacing with the Torque debugger, and other minor UI changes.

Let me know :)



Update :: July 19th
www.imgspace.net/thumb.php/I42dcf08d6251f.jpg
Added intellisense support and tidied-up the sidebar interface.
#41
07/23/2005 (10:48 am)
Yes, what I mentioned above is only for some types of class variables created like %variable = (what sort of object); and focus on member functions(methods), not on variables. And this is also the restriction of this type of script language like Torque script.

For now, I think the "pseudo-typing" idea is a good alternative soluction. It's even better If you can also complement it by auto-recognize some special variables as a object and built-in objects like MissionCleanup. Personally, I'll suggest that GG revise the torque script to support variable type declaration like other well known script languages in the near future.
#42
07/23/2005 (1:48 pm)
Regarding making TorqueScript strongly-typed, I have an idea. In order to be backward compatible, GG can simply let the people writing script decide whether to specify type or let Torque do it (as it does now). I'm still very new to Torque, so please forgive my pseudo-C++ example below:

int i; // specified by user as 32 bit integer type.
j; // let Torque figure it out.

Your Torque IDEs could then enable intellisense/autocompletion on all specified variables. You could let the user know this in the documentation, so if they're interested they will know to specify all variable types in their scripts.

I would ask to be a tester too, but, as I've already indicated, I am very new to Torque and TorqueScript. :)
#43
07/24/2005 (1:26 am)
Debugging support has been implemented!

www.imgspace.net/go/P42e34a93782e9.jpg
Mouseover view of variables, automatic enumeration of variables in local scope and retrieval in the variables view, full debug output in the "Output" tab, call stack visible in respective tab as well. On-the-fly breakpoints, on-the-fly variable assignment and step through/step into/step out support.

Utilizes the Enhanced TelnetDebugger by Tom Spilman. It won't work without it, and I do encourage anyone to merge the new debugger from Tom into their source. It works much better :)

I'll be sending out the new set of beta code to the chosen testers within the next day or so. A public beta will follow soon thereafter.

Here's my todo list:

- Psuedo-typing using // Decl %var type
- Configuration page which will enable/disable various options (such as scroll hint, colors, and other prefs)
- Various misc bug fixes that were listed on the Mantis pages

Any other suggestions are appreciated :)
#44
07/24/2005 (2:08 am)
I still use tribal IDE. The one feature I don't have but need,
is to be able to highlight some text , right click, then from the popup menu, do a search of the entire project.
In tribal IDE, it's annoying because you must copy and past it to the search panel.
#45
07/24/2005 (3:21 am)
@Sam:

If you have a PayPal acount just let me know, I'll donate for it! Hehe.

AWESOME

Steven
#46
07/25/2005 (5:32 am)
Alright folks! It's all set. I have released the public beta which is now available to the community. It expires on September 1st ... by that time I hope to have the final release out.

You can visit http://torque.netmercs.net/ for the links.

Any feedback is appreciated. I am also taking feature requests still.

- Sam
#47
07/25/2005 (6:22 am)
Sam, congrats, this editor is really cool, already has a lot of functions/features and looks and acts very professional :)
Just some minor things I've recognized so far:
- file history would be cool, also remembering the last used project directory on startup...
- and bracket matching didnt work for me, I had to adjust the spaces manually to match the brackets visually (hope you know what I mean).
- It should import files automatically if you select an existing project root
- maybe add *.mis to the import dialog by default
- is the intellisense/autocomplete implemented yet? how does it work?
Didnt test the debugger yet, but I'm sure it will work well, too...
If any Torque script editor will get me away from JEdit/TIDE, its probably this one - keep it up, man!
#48
07/25/2005 (6:39 am)
Hi Stefan,

> file history would be cool,

It remembers the last-opened project up to an unlimited amount. Are you speaking of a list of just files opened in the editor?

> also remembering the last used project directory on startup...
Consider it done.

> and bracket matching didnt work for me
It should automatically track {} [] and () pairs and highlight them blue when you are next to them. I just double-checked to see if this was happening, and it is:

www.imgspace.net/go/U42e4e96da4a4b.jpgIs this what you are speaking of, or did I mis-interpret you?

> It should import files automatically if you select an existing project root
While this may be ideal for some, I did not want to do it by default. Some may want to construct their own layout and not bother with a default import (for example, me :P)

> maybe add *.mis to the import dialog by default
Done

> is the intellisense/autocomplete implemented yet? how does it work?
Yes, sort of. Infopop text (the tooltip for function completion) is fully integrated. Intellisense/autocomplete only works for the scope resolution operator and for currently-defined functions only.

For example, I define a function: "function MyObject::MyFunction(%param1)"

When I type MyObject:: I will see a dropdown list with MyFunction listed.

The final version will include dot-completion (MyObject.function), and I will import all the default Torque objects and their corresponding functions.

Thank you for your input :)

- Sam

Edit -- Fixed image link... grr I wish GG would allow [img]..[/img] like every other bulletin board out there :P
#49
07/25/2005 (7:22 am)
Hi Sam,
ah, it remembers the recent project only if I've already re-opened a project file manually already ... creating a project, saving, restarting didnt work though... (I had to re-open it manually once, close again, and the next time it was there)

As far as bracket matching is concerned, I meant the indentation of the brackets, which didnt "line up" correctly for me ... but that might be a problem with my JEdit-edited buffers/files ... I'll check that on "fresh" script files later.

Thx for the intellisense info, looking forward to the final version :)

As for the auto-import, maybe add a checkbox
[x] Auto-import files?
... so lazy ppl like me dont need those exta-clicks to import manually ;)
#50
07/25/2005 (8:12 am)
Stefan,

> ah, it remembers the recent project only if I've already re-opened a project file manually already
Yeah... forgot to fix that. Added to my list; thanks :)

> As far as bracket matching is concerned, I meant the indentation of the brackets, which didnt "line up" correctly for me

It won't auto-format for you. If you paste it in unformatted, it won't format it, sadly. That feature's just a *bit* too complex to implement too easily at the moment.

If by bracket-matching, you mean this:

function asdf () {
// stuff
--------------------}

(---s because spaces aren't nbsps)

It won't do that. Primarily because some programmers code differently. I for one do not want my brackets/braces matched, since I put my opening { on the line of the function, if, while, foreach, etc and the closing brace on its own line.

Sometimes I have a tendency of doing this:

if (something) { dosomething; dosomethingelse; }

or

try {
// stuff
} catch {}

And since I can't predict everyone's coding style, or have an option for everyone's coding style, I figure I'd only enable smart indents (after { it'll indent; after } it'll outdent) and let people do their own style of bracketeering :)

> As for the auto-import, maybe add a checkbox
Sure :P
#51
07/25/2005 (9:30 am)
@Sam
I just downloaded your beta and looks good so far. One thing that I didn't like was that when you import a project, all of the folders are expanded. Could you possibly change this or make it an option to collapse them. Also a collapse folders option when you right click on a folder in the project would be great.

EDIT:
A few other things I noticed.
If you go to edit->preferences->syntax highlighting then click adjust, the sample text runs off the right side of the window. It gets clipped by the window but still looks like it isnt positioned correctly.

Sorting in the project list. The current project list sorts all files alphabetically. Is it possible you can make it display folders first alphabetically followed by individual files alphabetically?

EDIT again:
I currently use Perforce as my source control and many of my files are currently write protected. Anyways to the point, the IDE crashes if you try to save a write protected file.
#52
07/25/2005 (10:25 am)
@Sam
Just posted up a few bugs in your DB. Is it possible for you to set the mantis setting so that the reporter of the bug can edit his own bug? I didnt set my categories right for the bugs and couldnt go back and edit it. Also I wanted to attach more than 1 pic to a bug but I couldnt.
#53
07/25/2005 (10:52 am)
> Is it possible for you to set the mantis setting so that the reporter of the bug can edit his own bug?

Done
#54
07/26/2005 (1:55 am)
Nice work. Just testing it out now.

A small request (although it might be too small a nit to address just yet):
I'd like the tree view to list files before subfolders. I know the convention is the opposite,
but for a tree view, if you have subfolders expanded, it's much easier to answer
"what's in this folder" if the files are directly below the containing folder, rather than
below whole sutrees so you really have to concentrate to match up the indenting
with the right containing folder far above
#55
07/26/2005 (8:10 pm)
Great IDE I love it.
One problem I had is, on installing, I got the popup to go and install Microsoft.net V1.045678? but on the Microsoft page I saw V2.2 so I thought that was what I needed and I went ahead and installed that, but it didn't work, so I had to go back for V1.1 redistributable and it worked.
I hope this V2.2 wont cause me problems.
I think, for noobs like me, the popup could have been more specific about how to get what is needed.
#56
07/26/2005 (9:04 pm)
Yes I can fix that for the installer.

It will only run on 1.1.
#57
07/27/2005 (2:12 am)
I can't get the breakpoints to work, even now that sarting a debug session finally goes smoothly. Although I get no errors or warnings from TorqueDev, I suspect I'm not enabling debugging the right way in my script or something (never used the debugger before). Can anyone provide a clear recipe for what's required from the script code, command line, or whatever other settings are needed to get this to work?
#58
07/27/2005 (2:27 am)
Hi Joachim,

Please refer to this thread on the TorqueDev forums on how to enable debugging.
#59
07/27/2005 (2:39 am)
Works now. Awesome feature!

Which leads me to the next feature request: the debug operations would be very useful to have on the toolbar (more so than half the things that are there). Or possibly as context choices on the highlit line.
#60
07/27/2005 (12:31 pm)
When I set a breakpoint and trace into the code, for a while the error: "no last element of a zero sized array!" will always show up. Anybody has this problem?