IDEA: Change TorqueScript Extension
by James Urquhart · in Torque 3D Professional · 05/20/2014 (6:18 am) · 28 replies
Since its inception, TorqueScript has used the "cs" extension (short for either C Script or Console Script). Unfortunately when CSharp appeared in 2000, Microsoft commandeered the "cs" extension.
As a consequence, every major text editor now assumes a cs file is a CSharp file, meaning you often get horribly formatted highlighting in practically every editor. Making your own syntax highlighting configuration is difficult since they often go by file extension and of course cs is taken. Even worse when you want to open a script, you may find that software such as Visual C# decides to open it.
On code sharing websites such as github, it's also hard to search for TorqueScript code as if for example you search for "cs" files you'll get CSharp code.
In light of these problems, I propose the default extension be changed to something more sensible, such as "ts" for "Torque Script".
As a consequence, every major text editor now assumes a cs file is a CSharp file, meaning you often get horribly formatted highlighting in practically every editor. Making your own syntax highlighting configuration is difficult since they often go by file extension and of course cs is taken. Even worse when you want to open a script, you may find that software such as Visual C# decides to open it.
On code sharing websites such as github, it's also hard to search for TorqueScript code as if for example you search for "cs" files you'll get CSharp code.
In light of these problems, I propose the default extension be changed to something more sensible, such as "ts" for "Torque Script".
About the author
#3
05/20/2014 (6:56 am)
I think the reason they haven't is because the only decent ts editor is torosion and it expects a cs extension.
#4
05/20/2014 (7:01 am)
You can change it in preferences.
#5
And you can add extensions to the current set if you decide to add, say, hlsl so you can edit your shaders in Torsion - or TAML....
05/20/2014 (7:31 am)
True that.And you can add extensions to the current set if you decide to add, say, hlsl so you can edit your shaders in Torsion - or TAML....
#6
It has always made more sense to me.
05/20/2014 (8:12 am)
Tbh I've already been using the .ts extension from time to time in my private code lol :PIt has always made more sense to me.
#7
It will break existing projects though, so I think it'll have to be done in 4.0.
05/20/2014 (9:00 am)
Sounds like a good idea to me. It will break existing projects though, so I think it'll have to be done in 4.0.
#8
05/20/2014 (9:45 am)
Would agree for 4.0.
#9
You're going to have to come up with an unused extension and good luck for anything less than five characters that isn't already commonly used for other things.
05/20/2014 (12:52 pm)
Again, .ts is reserved for MPEG 2 Transport Stream files which are normally created by anything that captures OTA (Over the air) television broadcasting and other video production tools.You're going to have to come up with an unused extension and good luck for anything less than five characters that isn't already commonly used for other things.
#10
Fair point, though normally you don't edit .ts files in text editors and scripters are unlikely to want to frequently open MPEG 2 .ts files from the OS file browser.
Of course any other useful suggestions are welcome, thats why I made this post! ;)
05/20/2014 (12:57 pm)
@NathanFair point, though normally you don't edit .ts files in text editors and scripters are unlikely to want to frequently open MPEG 2 .ts files from the OS file browser.
Of course any other useful suggestions are welcome, thats why I made this post! ;)
#11
05/20/2014 (1:09 pm)
This is the kind of change that could and should affect both engines. Imagine if T3D used .ts and T2D used .cs. I foresee much confusion in the future if that happened.
#13
Mich, do you think people would like this to happen in T2D? If so I guess the committees could coordinate the changeover somewhat.
As for this being a 4.0 change, I agree. I think it should be done whenever we introduce new script templates, which have been on our radar for quite a while. Which will probably happen in 4.0. :P
05/20/2014 (2:03 pm)
I've been saying this for a while ;P. I definitely agree. Unfortunately .ts refers to TypeScript so we'd run into the same issues. I'd vote for .tqs, after some reflection. It doesn't seem to be very common, and it's certainly not another programming language. Maybe we could even just go .tq.Mich, do you think people would like this to happen in T2D? If so I guess the committees could coordinate the changeover somewhat.
As for this being a 4.0 change, I agree. I think it should be done whenever we introduce new script templates, which have been on our radar for quite a while. Which will probably happen in 4.0. :P
#14
05/20/2014 (2:15 pm)
General chat seems to be trending towards .tcs for simplicity of conversion, and as a final step when rolling in the consolerefactor branch to mark the demarcation, fwiw.
#15
.......................,,-~*~,,
......................./:.:.:.:.:.|
......................|;.;.;.;.;./
......................|.;.;.;.;.|
............._,,,,,_.).;.;.;.;.|
.........,,-":.:.:.:."~-,;.;.;.|
........(_,,,,---,,_:.:.);.;.;..",,
......,-":.:.:.:.:.""-,,/;.;.;.;.;.",
.....(:.__,,,,,,,,,___);.;.;.;.;.;|
...../"":.:.:.:.:.:.:¯"";.;.;.;.;.,"
....",__,,,,,,,,,,,__/;;;;;;;;;/
......::.:.:.:.:.:.:.;.);;;;;;;;;/:
.......,,,,,---~~~~;;;;;;;;,"::::
.........."""~~--,,,,,,,,,,-"::::::::::
...................::::::::::::::::::::::::
GARAGE GAMES,
PLS ADD THIS!!
05/20/2014 (2:31 pm)
.......................,,-~*~,,
......................./:.:.:.:.:.|
......................|;.;.;.;.;./
......................|.;.;.;.;.|
............._,,,,,_.).;.;.;.;.|
.........,,-":.:.:.:."~-,;.;.;.|
........(_,,,,---,,_:.:.);.;.;..",,
......,-":.:.:.:.:.""-,,/;.;.;.;.;.",
.....(:.__,,,,,,,,,___);.;.;.;.;.;|
...../"":.:.:.:.:.:.:¯"";.;.;.;.;.,"
....",__,,,,,,,,,,,__/;;;;;;;;;/
......::.:.:.:.:.:.:.;.);;;;;;;;;/:
.......,,,,,---~~~~;;;;;;;;,"::::
.........."""~~--,,,,,,,,,,-"::::::::::
...................::::::::::::::::::::::::
GARAGE GAMES,
PLS ADD THIS!!
#16

Apparently there are still people who don't understand the MIT license..
@Chris GarageGames are no longer in charge of T3D, you should direct your encouragement at the Steering Committee of T3D.
05/20/2014 (2:52 pm)

Apparently there are still people who don't understand the MIT license..
@Chris GarageGames are no longer in charge of T3D, you should direct your encouragement at the Steering Committee of T3D.
#17
05/20/2014 (4:53 pm)
How about .torquescript? No confusion is possible, though it's a bit unwieldy....
#18
I know, it was a joke based on the "VALVE, PLS ADD THIS!!" ASCII thumbs posted in the TF2/CS:GO workshop.
05/20/2014 (6:04 pm)
@LukasI know, it was a joke based on the "VALVE, PLS ADD THIS!!" ASCII thumbs posted in the TF2/CS:GO workshop.
#19
05/20/2014 (6:40 pm)
I'm fine with .tcs! The consolerefactor branch is slated for inclusion in 3.7, as well as some other script-related issues... so I guess this would fit, but I think it's more than a minor version change...
#20
05/20/2014 (7:02 pm)
Whatever the decision, I do agree with Daniel's last statement. Even if the contents of a file do not change, changing the extension of a language (thus, hundreds of files) is best reserves for a major version change. On that note, I think the T2D and T3D steering committees are long overdue for a synch. Perhaps some cross-committee forum threads are in order.
Associate Steve Acaster
[YorkshireRifles.com]
No wait ... actually this isn't a bad idea ...