Barrel roll?
by JP · in Torque Game Engine · 11/17/2008 (4:41 pm) · 3 replies
I have a flying vehicle and when I double tap a key I want the vehicle to perform a complete barrel roll to the side, sort of like what the banshee does in Halo 2. Any ideas how to do this?
If something like this has been asked before, I apologize. I did a search for "barrel roll" but nothing useful came up.
If something like this has been asked before, I apologize. I did a search for "barrel roll" but nothing useful came up.
#2
I know about the rollforce stuff. My vehicle already rolls when I hold down A or D. What I'm looking for is a key bind that will make the vehicle do a complete roll and move it to the side without holding down the key. It's a move that would be used for dodging missiles and such.
11/18/2008 (2:50 pm)
Thanks for the reply.I know about the rollforce stuff. My vehicle already rolls when I hold down A or D. What I'm looking for is a key bind that will make the vehicle do a complete roll and move it to the side without holding down the key. It's a move that would be used for dodging missiles and such.
#3
11/18/2008 (3:56 pm)
Without putting to much thought into it, what comes to mind first is to have a timer that is triggered with each press of the keyif(LEFT)
{
if(leftTimer$ < 1sec.)
barrelRollLeft();
else
moveLeft();
leftTimer$ = 0;
}
Associate Michael Hall
Distracted...