Torque Game EngineTorque Game Engine Documentation
Version 1.3.x

Setting up Torque on Windows

Preparing Your System

You don't have to do much to get your system ready to work with Torque. On Windows, simply ensure you meet the system requirements listed below:

System Requirements

Update your video card drivers! The Torque Game Engine utilizes OpenGL for its rendering. OpenGL support is packaged in video card drivers, which are distributed by video card manufacturers and are constantly being updated. Make sure you have the latest drivers for your particular video card. Most manufacturers have websites with simple driver download instructions. Ensuring that you have the latest drivers is critical to running Torque.

Required Hardware:

  • Pentium I, II, III, IV, AMD Athlon, 64, etc.
  • 64MB RAM or more, highly dependent on your application
  • 3D Hardware accelerated video card such as AGP Radeon or GeForce class cards.

Required Software:

  • Windows 98, NT w/ SP6+, 2K w/ SP4+, XP w/ SP1+
  • Remember: get the latest drivers for your video card!
  • DirectX version 8.0 or later.
  • OpenAL Runtime or SDK Installation.

Development Tools:

  • Visual C++ 6.0, 7.0, or 7.1. GCC and other free compilers will also work, but GarageGames does not officially support them.
  • It is also recommended that you download some tools like JEdit (and the JEdit TorqueIDE), WinGrep (for easily searching text), and WinMerge (for merging separate codebases, if necessary).

Summary

Please note: though the engine has fairly minimal requirements as far as hardware, the performance of any particular game built using the TGE will depend greatly on how each game makes use of the resources available to it. TGE games can be anything, from very low-demand applications such as small 2D game "toys" to high end (and high framerate) 3D Role Playing Games, First Person Shooters, Racers, Flight Simulators, and whatever you can dream up! Torque is a high-performance engine, it is up to you how far your own content will stress a user's systems.

Now that you have the source code downloaded, and your system is ready, read on to learn how to compile the code. You can use the links below to select your specific compiler:

Compiling the Torque Game Engine SDK with Microsoft Visual C++ .NET 2003 (7.1)

Abstract

This guide explains the build process for projects in the Torque Game Engine using Microsoft Visual C++ .NET 2003 (7.1)

Please note: this guide is intended for developers with Visual C++ .NET version 2003 (also called version 7.1). If you have version 2002 (also called version 7.0) your build procedure is much different, please go here

Step 1: Installation

Building the Torque Game Engine (TGE) with Visual C++ 7.1 is a simple process.

You should already have the most recent stable version of TGE downloaded to your system. If you do not, go to your My Garage homepage and follow the download links. You must also have the basic software required by the TGE installed and configured on your machine. This includes up to date system software, extensions, and drivers. Please refer to the TGE system requirements page for specific details.

If you have not yet done so, you'll also need to install your copy of Visual C++ 7.1. Follow the installation instructions which came with your package. The installation process differs slightly depending on whether you have a standard, professional, enterprise, or other edition of VC++ 7.1. You don't need to do anything special in the installation; Torque will compile with VC++ 7.1's default installation components.

Step 2: Configuring Visual C++ 7.1

One quick configuration needs to be performed in order to work with the TGE in VC++. The Torque Game Engine uses the common .cc file extension for all its C++ source files. Unfortunately, Visual C++ does not automatically recognize the .cc file extension, so we need to add support for it.

We provide a file, called "VC7 .cc compiling.reg" , that will modify the Windows registry to add .cc support to Visual C++.

To run this file, open the directory to which you installed Torque, for example "C:\Torque" , and navigate to the "vc7" sub-directory. Double-click and run the file "VC7 .cc compiling.reg"

A dialog will appear asking you to confirm the change to the registry:


                            Confirm Registry

Confirm Registry

Click the "Yes" button.

Your copy of VC++ 7.1 is now ready to work with the Torque Game Engine.

Step 3: Building The Torque Demo

Once again, open the directory to which you installed Torque and navigate to the "vc7" sub-directory.

Double-click the file "Torque SDK.sln" to open the file in VC++. This is the basic solution file for the Torque SDK, and it is from this file that we can build the Torque demo.

In the Visual C++ Solution Explorer, click the "Torque Demo" list item.


                            Solution Explorer

Solution Explorer

Now, click the "Build" menu, and select the "Build Torque Demo" command.


                            Build Project

Build Project

Visual C++ will start building the torqueDemo.exe application. You can watch the results of this build in VC++'s Output window.


                            Output Window

Output Window

It may take a few minutes to complete, but you will end up with a working copy of the file "torqueDemo.exe" in the "example" sub-directory of your Torque folder.

Congratulations, you have successfully built the Torque Demo, and your system is ready to work with the Torque source in VC++ 7.1!

Compiling the Torque Game Engine SDK with Microsoft Visual C++ .NET 2002 (7.0)

Abstract

This guide explains the build process for projects in the Torque using Microsoft Visual C++ .NET 2002 (7.0) Please note: this guide is intended for developers with Visual C++ .NET version 2002 (also called version 7.0). If you have version 2003 (also called version 7.1) your build procedure is much different, please go here.

Step 1: Prerequisites

Building the Torque Game Engine (TGE) with Visual C++ 7.0 is a simple process.

First off, it should be noted that the build instructions offered here are not as detailed as those offered for other versions of VC++. VC++ 7.0 is, in general, more difficult to work with than other version of the product.

Before beginning this guide, you should have the most recent stable version of the TGE downloaded to a directory on your system. If you have not done so already, please go to your My Garage homepage and follow the download links. You must also have the basic software required by the TGE installed and configured on your machine. This includes up to date system software, extensions, and drivers. Please refer to the TGE system requirements page for specific details. It is assumed that VC++ .NET 7.0 is installed and working as well.

Step 2: Configuring Visual C++ 7.0

Four additional configurations are necessary in order to smooth the TGE experience in VC++ 7.0.

Configuration Step 1) Install Microsoft .NET Framework 1.0 Service Pack 2

Before beginning work with Visual C++ .NET 2002, you should download and install the latest .NET Framework 1.0 service pack directly from Microsoft. See Microsoft's Visual Studio Update Page, find the .NET Framework 1.0 service pack, and follow Microsoft's download and installation instructions.

Configuration Step 2) Add .cc file support

The Torque Game Engine uses the common .cc file extension for all its C++ source files. Unfortunately, Visual C++ does not automatically recognize the .cc file extension, so we need to add support for it.

We provide a file, called "VC7 .cc compiling.reg" , that will associate .cc files with Visual C++ by modifying the Windows registry.

To run this file, open the directory to which you installed Torque, for example "C:\Torque" , and navigate to the "vc7" sub-directory. Double-click and run the file "VC7 .cc compiling.reg"

A dialog will appear asking you to confirm the change to the registry:


                                Confirm Registry

Confirm Registry

Click the "Yes" button.

Configuration Step 3) Convert project files to VC++ 7.0

The VC++ .NET solution files included in the TGE are configured for VC++ .NET 2003 (version 7.1). Unfortunately, Microsoft did not make the 7.1 solution files backward compatible with VC++ 7.0. This flaw must be worked around. One solution is to convert the Torque VC++ 6.0 project files to VC++ 7.0. The procedure for doing so is described below.

Open the directory to which you installed Torque. Next, open the "v6" sub-directory. You will need to convert each of these files from Visual Studio 6.0 to Visual Studio 7.0 format. To do so, double-click the file "Torque SDK.dsw" Note that once the files have been converted, they will no longer be readable by Visual C++ 6.0. If you would like to back these files up, do so now.

Visual Studio 7.0 will open and ask you if you'd like to convert each file. Follow the dialog boxes that appear, and agree to convert each file.

The files should now correctly load in your copy of VC++.

Configuration Step 4) Set Working Directory

Unfortunately, VC++ 7.0 does not preserve the project working directory properly when converting from 6.0 project files. In order to properly build and run the Torque Demo, this must be corrected.

To do so, pop up the "Properties" dialog for the Torque Demo project. Select the "Debugging" item from the "Configuration Properties" list on the left. Under the "Action" section, fill in the "Working Directory" field with the following value: ../example

VC++ 7.0 should now be properly configured to work with the TGE.

Step 3: Building The Torque Demo

To build the Torque Demo, click the "Torque Demo" item in the solution explorer, and build it in the usual way. The file "torqueDemo_DEUBG.exe" should be output to the "example" sub-directory of your Torque folder.

You have now built the Torque Demo.

Note: Visual C++ 7.0 is more difficult to support than other versions of the product. Please accept our apologies that this guide isn't more detailed. If you would like to contribute additional instructions or screenshots, please do! Email joshw@garagegames.com with an appropriate subject line to do so.

Compiling the Torque Game Engine SDK with Microsoft Visual C++ 6.0

Abstract

This guide explains the build process for projects in the Torque using Microsoft Visual C++ 6.0

Installation

You should already have all required software installed and configured. This includes up to date system software, extensions, and drivers. Please refer to the TGE system requirements page for specific details. Installing, configuring and building with Visual C++ 6.0 is a simple 4 step process. If you already have installed Visual C++ on your computer please review each step carefully, especially Step 3: Configuring Visual C++ 6.0 to make sure your computer is configured correctly.

The Torque Game Engine has been tested for compatibility with Visual C++ Standard Edition, Visual C++ Professional Edition and Visual C++ Enterprise Edition.

When you are ready to install, insert the Visual C++ CD-Rom and proceed to the Common Install Folder dialog . We will assume that you install Visual C++ to the default recommended folder 'C:\Program Files\Microsoft\Visual Studio\Common' .


                            Install Common Folder Dialog

Install Common Folder Dialog

Proceed to the Installation Setup Dialog and install to the default folder 'C:\Program Files\Microsoft\Visual Studio\VC98' . Choose the Typical Install button to continue.


                            Install Folder Dialog

Install Folder Dialog

Proceed to the Setup Environment Variables Dialog . Make sure the 'Register Environment Variables' check box is CHECKED. Registering the environment variables is needed for the command line tools and our makefiles to function properly. Click OK to continue.


                            Register Environment Variables

Register Environment Variables

Congratulations you are done installing VC++ 6.0! Proceed to the next section for instructions on downloading and installing VC++ 6.0's Service Pack 5.

Step 2: Installing Service Pack 5 for Visual C++ 6.0

Microsoft has issued several updates and bug fixes to Visual C++ 6.0 since it was originally released. Service Pack 5 is a cumulative collection of all previous service pack updates (SP4, SP3, SP2, and SP1) and includes fixes.

To read more about or download Service Pack 5 visit the Microsoft Service Pack 5 download page . Follow the instructions on the page to begin the download.

The download is large, 133mb. The download page has complete setup instructions; you will have plenty of time to read them while you are downloading the service pack. When the download is complete, follow the directions provided with it and install the Service Pack.

Step 3: Configuring Visual C++ 6.0

One quick configuration needs to be performed in order to work with the TGE in VC++. The Torque Game Engine uses the common .cc file extension for all its C++ source files. Unfortunately, Visual C++ does not automatically recognize the .cc file extension, so we need to add support for it.

We provide a file, called "VC6 .cc compiling.reg" , that will modify the Windows registry to add .cc support to Visual C++.

To run this file, open the directory to which you installed Torque, for example "C:\Torque" , and navigate to the "vc6" sub-directory. Double-click and run the file "VC6 .cc compiling.reg"

A dialog will appear asking you to confirm the change to the registry:


                            Confirm Registry

Confirm Registry

Click the "Yes" button.

Your copy of VC++ 6 is now ready to work with the Torque Game Engine.

Step 4: Building w/ Project Files

Step 4: Building w/ Project Files

Once again, open the directory to which you installed Torque and navigate to the "vc6" sub-directory.

Double-click the file "Torque SDK.dsw" to open the file in VC++. This is the basic workspace file for the Torque SDK, and it is from this file that we can build the Torque demo.

Now that the project file is open we can build the Torque Test application by going to the "Build" menu and selecting Build torqueDemo_DEBUG.exe . Alternatively, you can build the demo with the shortcut key, F7.


                            Build Project

Build Project

The demo application can take several minutes to compile depending on the speed of your computer and the amount of free memory. As each file is compiled, it will be listed in the output window. Be patient. You can watch the results of this build in VC++'s Output window.

It may take a few minutes to complete, but you will end up with a working copy of the file "torqueDemo_DEBUG.exe" in the "example" sub-directory of your Torque folder.

Congratulations, you have successfully built the Torque Demo!

If you wish, you can run the Torque Demo in the VC++ debugger by going to the "Build" menu and selecting "Start Debug" and then selecting "Go" . Alternatively, you may use the F5 shortcut key to debug.


                            Start Debugger

Start Debugger

That's it, you're system is playing happily with TGE and VC++ 6!

Summary

Now that you've dbuilt the demo, read the Torque Demo Application section to learn how to use it!