TGE Scripting language
by Ian Roach · in Torque Game Engine · 02/20/2002 (3:12 am) · 1 replies
Hello Everyone.
After reading the excellent TGE Scripting Resource ive got a few questions.
One of my main questions is player movement. After looking at the player.cs script im curious where the MoveForward functions e.t.c are defined ?
I want to have 2 sorta play modes. Like Assualt mode and normal mode which is activated at the press of a button.
How can i go about doing this. Do i just define all my functions for moving in every direction again (becuase player movemet will be faster) or is there any way to use the inheritance te original player movement code.
In addition i would like to know about the possiblily of adding jetpacks. With this activated the jump button would become the increase height button crouch, decrease height e.t.c
My question is how do i go about defingin movement upwards e.t.c
do i use a datablock which uses elements of player movement ?
Im a little confused how the player.cs file gets its movement.
Appreciate any help you can give me :)
After reading the excellent TGE Scripting Resource ive got a few questions.
One of my main questions is player movement. After looking at the player.cs script im curious where the MoveForward functions e.t.c are defined ?
I want to have 2 sorta play modes. Like Assualt mode and normal mode which is activated at the press of a button.
How can i go about doing this. Do i just define all my functions for moving in every direction again (becuase player movemet will be faster) or is there any way to use the inheritance te original player movement code.
In addition i would like to know about the possiblily of adding jetpacks. With this activated the jump button would become the increase height button crouch, decrease height e.t.c
My question is how do i go about defingin movement upwards e.t.c
do i use a datablock which uses elements of player movement ?
Im a little confused how the player.cs file gets its movement.
Appreciate any help you can give me :)
About the author
Associate Stefan Beffy Moises
For switching speed, the easiest way would be to switch the players datablock by assigning a key to a function you had to write, but I think you can only set the datablock on player creation...
So I guess you have to write a function to change speed, etc. in player.cc and make it accessible through scripting...