Author Topic: Afterburners  (Read 672 times)

I was editing the F18 script, and decided to make it have afterburners. I can it make so when you press spacebar, you go faster, but only in one direction. So if i face one way, i go fast forwards, but the other way i go fast backwards. How would i make it so you go faster the way your looking?

Code: [Select]
// spacebar!
   function F18Vehicle::onTrigger(%this,%obj,%client)
   {

%obj.setvelocity("5000 0 0"); //this

   }

Would probably require some use of %client.player.getForwardVector(); or something involving getting their aim... meh.

try looking at the turbo jeep script

Would probably require some use of %client.player.getForwardVector(); or something involving getting their aim... meh.
Tried that, didn't work.

You know how fast 5000 is right? It is so fast that you will vaporize. Thats how fast. Exacteley what we need :3
Can you make fireB emitters?

Try something like

%obj.setVelocity(vectorScale(%client.player.getForwardVector(),2));

Or you Where did that come from?
« Last Edit: June 30, 2010, 11:49:11 PM by Headcrab Zombie »

You could probably do something like:
%veldir=%client.player.getForwardVector();

Then just call %veldir.