TorqueScript Console Functions 18

From TDN

Section Index


1. OpenAL || 2. Debugging || 3. String Manipulation || 4. Networking || 5. Console || 6. Device I/O || 7. File I/O
8. Packages || 9. Objects || 10. Event Scheduling || 11. Datablocks || 12. Video / Texturing || 13. Special || 14. Resource Management
15. Scene || 16. Containers and Raycasts || 17. Editors || 18. Build || 19. Time || 20. GUIs || 21. Math


This quick reference guide was taken directly out of The Game Programmer's Guide to Torque by Edward Maurina. It's an outstanding resource - a must for anyone wanting to get serious about programming in Torque.

Contents

Build

getBuildString()

Purpose
Use the getBuildString function to determine if this build is a "Debug" release, or a "Release" build.

Returns
Returns a string, either "Debug" for a debug build, or "Release" for a release build.

See Also
getCompileTimeString, getVersionNumber, getVersionString, isDebugBuild

echo(":" @ getBuildString() @ ":");
// prints 
// :Release:
// or
// :Debug:



getCompileTimeString()

Purpose
Use the getCompileTimeString function to determine when the currently running engine was built.

Returns
Returns a string containing "Month Day Year at Hour:Minute:Second" showing when this executable was built.

See Also
getBuildString, getVersionNumber, getVersionString, isDebugBuild

echo(":" @ getCompileTimeString() @ ":");
// print example:
// :May  3 2007 at 16:08:23:



getVersionNumber()

Purpose
Use the getVersionNumber function to get the version number of the currently executing engine.

Returns
Returns an integer representing the engine's version number.

See Also
getBuildString, getCompileTimeString, getVersionString, isDebugBuild

echo(":" @ getVersionNumber() @ ":");
// print example:
// :1520:
 



getVersionString()

Purpose
Use the getVersionString function to get the version name and number for the currently executing engine.

Returns
Returns a string containing a name and an integer representing the engine's version type and version number.

See Also
getBuildString, getCompileTimeString, getVersionNumber, isDebugBuild

echo(":" @ getVersionString() @ ":");
// print example:
// :Torque Demo 1.5.2 (TGE 1.5.2):



isDebugBuild()

Purpose
Use the isDebugBuild function to determine if this is a debug build.

Returns
Returns true if this is a debug build, otherwise false.

See Also
getBuildString, getCompileTimeString, getVersionNumber, getVersionString

echo(":" @ isDebugBuild() @ ":");
// print example:
// :0:
// or
// :1:


Section Index


1. OpenAL || 2. Debugging || 3. String Manipulation || 4. Networking || 5. Console || 6. Device I/O || 7. File I/O
8. Packages || 9. Objects || 10. Event Scheduling || 11. Datablocks || 12. Video / Texturing || 13. Special || 14. Resource Management
15. Scene || 16. Containers and Raycasts || 17. Editors || 18. Build || 19. Time || 20. GUIs || 21. Math