Game Development Community

Torque Script Variables

by Edward Pilecki · in Torque Game Engine · 07/11/2005 (6:25 pm) · 5 replies

Maybe someone can point me in the right direction here. Im new to the Torque Engine and to Torque Script. Im pretty good at C++ Programming. Im trying to figure out where you can find a list of variables that you can manipulate in the Scripting control. For example some of the Movement variables for the player (FPS Kit) are denoted as beginning with "mv" then the rest of that variables name is listed. I have seen these in Finney's book but I would like to see the rest of the variablest that the engine uses and that we can manipulate through the scripting code. I know that we can generate our own but I can see that there are certain globals that you have access to that directly manipulate things inside of the engine. The one variable that I am looking for specifically is the current speed of the player, or maybe the acceleration. I need to be able to control these variables. Are they avaliable through the scripting language? or do we have to expose them in the C++ code so that we can manipulate them by the scripting. Pointing me to documentation of all of the variables that you can manipulate through the scripting language would be beneficial, or how to generate the documentation on my own would also be helpful.

Thanks in advance for the help, and if you need any clarification on this just let me know :)

About the author

Recent Threads


#1
07/11/2005 (9:34 pm)
Have you tried using the autodoc functionality?
#2
07/15/2005 (9:16 am)
Perhaps this resource can help you out.
(it was generated via the autodoc functionality ;))
#3
07/19/2005 (12:50 am)
Thanks for the help pointing me to the autodoc resources, but I have already looked at them. They provide a good source for the functions that are avaliable and they also show what those functions do, but they don't show what the global variable are that you can manipulate. I guess I should state that I'm lookin for the definitions of all of the global variables that the engine uses that we have access to through the scripting language, such as the players current acceleration or direction. One of the examples of the global variables that we can manipulate is "$mvLeftAction" this is not a variable that we create or one that is defined in the scripting language. This leads me to beleive that it is defined in the actual C code of the engine. I just want to know if there is a list of these variables that we can manipulate through the scripting language that have their definitions in the C source code. Let me know if I need to be more clear.
#4
07/19/2005 (6:03 am)
...
#5
07/19/2005 (12:26 pm)
Thats perfect! I can't believe that I didnt find that resource! But what you posted is exactly what Im lookin for thanks a lot. I guess I just have to look around more.