Questions about Torque programming language and about "torque project files"
by Paris Emanuele · in Torque Game Engine · 02/19/2009 (4:54 am) · 7 replies
Hi all, I've some questions about Torque:
1st one:
How can I program in the Torque talking about programmation? For example, if I create some missions, have I to use Torquscript or I can simply use C++ for script exc? If I've to set some parameters (for example some weapons parameters, like the firepower exc) have I to program them in Torquscript or C++?
2nd one: are there "VC++ project files" in TGE (and TGEA)? I see only a lot of .cc and .h files but it's impossible to work without a "project file". In "VS2005" or "VC6" or "vc7" folders there are some VC++ project files but don't like they're Engine or Game Projects.
Thank you,
Akabane
1st one:
How can I program in the Torque talking about programmation? For example, if I create some missions, have I to use Torquscript or I can simply use C++ for script exc? If I've to set some parameters (for example some weapons parameters, like the firepower exc) have I to program them in Torquscript or C++?
2nd one: are there "VC++ project files" in TGE (and TGEA)? I see only a lot of .cc and .h files but it's impossible to work without a "project file". In "VS2005" or "VC6" or "vc7" folders there are some VC++ project files but don't like they're Engine or Game Projects.
Thank you,
Akabane
About the author
#2
1b: There's a time and place for using both script and C++, which varies from project to project. Modifying weapon parameters would be done in script for that particular weapon. Creating gametype mechanics would generally be done in script. Adding a new object class, enhancing the physics, altering the rendering setup, etc would be done in C++.
2a: In TGE your overall "solution" file will be found in the VS2005 directory, it's the "Torque SDK.sln" file. This "solution" file can also be imported and then updated in VS2008. There are also individual "project" files for different components and/or tools usable by Torque. Same deal with the VC project files. It's generally easier nowadays to simply use the VS2005 or VS2008 project/solution files, and there's no reason not to since VS Express editions are available for free.
2b: In TGEa the projects and solution files are found in the "GameExamples/GAMENAME/buildFiles" directories. If you use the template project in order to start a "new" project a "buildfiles" directory will be placed in you project directory and will contain solutions for VS2005, VS2008, and XCode.
02/20/2009 (8:31 am)
1a: You'll create and paint your terrains in the Mission Editor, and you'll place objects there also. The mission file is then saved as a simple text file in the missions directory. You could conceivably procedurally generate random missions, but that will take some programming effort in both C++ and script.1b: There's a time and place for using both script and C++, which varies from project to project. Modifying weapon parameters would be done in script for that particular weapon. Creating gametype mechanics would generally be done in script. Adding a new object class, enhancing the physics, altering the rendering setup, etc would be done in C++.
2a: In TGE your overall "solution" file will be found in the VS2005 directory, it's the "Torque SDK.sln" file. This "solution" file can also be imported and then updated in VS2008. There are also individual "project" files for different components and/or tools usable by Torque. Same deal with the VC project files. It's generally easier nowadays to simply use the VS2005 or VS2008 project/solution files, and there's no reason not to since VS Express editions are available for free.
2b: In TGEa the projects and solution files are found in the "GameExamples/GAMENAME/buildFiles" directories. If you use the template project in order to start a "new" project a "buildfiles" directory will be placed in you project directory and will contain solutions for VS2005, VS2008, and XCode.
#3
Thanks for all other answers ^^
02/20/2009 (10:37 am)
1a: If I create some script during a mission (for example an ingame cut-scene) what should I do? I should to progrm in C++ or Torquscript the scripts? (Hope I explained clearly)Thanks for all other answers ^^
#4
You can do a lot with triggers and a pathed camera, and even the Theora object gui control, all of which can be handled in script. But there would still have to probably be some C++ work done in the background -- especially for anything really complicated.
02/20/2009 (2:08 pm)
Some sort of triggered action event could be done in script. Calling an in-game cut scene to be played could be done in script. You can do a lot with triggers and a pathed camera, and even the Theora object gui control, all of which can be handled in script. But there would still have to probably be some C++ work done in the background -- especially for anything really complicated.
#5
02/21/2009 (6:01 am)
Thank you very much ^^
#6
02/23/2009 (2:19 pm)
Hi all, i have the same kind of dilemma as Emmanuel, I just got the engine today. I know I need to do a lot of digging around to find resources, but all sample codes/examples I have found in the forum are torqueScript related. Is there anywhere to find some useful c++ documentation/tutorial modying engine code (where does the game logic go, what are some of the main classes we need to derive from to get going in c++). Its very frustrating to look for code samples and only find torqueScript, I don't have anything against scripting (when it makes sense) but I want to use it as little as I can and harness the power of C++ as much as possible. Thanks
#7
02/23/2009 (2:29 pm)
@CrimsonJohan: keep looking. There's a lot more than just script examples in the Private forums and in the Resources section.
Torque Owner Paris Emanuele