Home   Help Search Login Register  

Author Topic: speed  (Read 473 times)

0 Members and 2 Guests are viewing this topic.

Piraneous

  • Guest
speed
« on: 28 Jan 2004, 10:08:29 »
ok,  i've just got back into scripting again and i'm a bit rusty. want to make what should be a fairly simple script that will detect the speed of a vehicle and when it slows below a given speed it sets a variable to true which i can then use to activate another trigger

any ideas?

CrashnBurn

  • Guest
Re:speed
« Reply #1 on: 28 Jan 2004, 10:47:24 »
speed unitname < 5
... or whatever speed you want to use.

Piraneous

  • Guest
Re:speed
« Reply #2 on: 28 Jan 2004, 10:57:37 »
well that works for setting off the trigger,  but now the problem is, when the chopper spawns, its speed it already less than 5 so the trigger activates straight away.

Offline LCD

  • Former Staff
  • ****
    • Everon Cartel
Re:speed
« Reply #3 on: 28 Jan 2004, 11:14:09 »
@ speed heliname > 5
@ speed heliname < 5

in a script it wil wait til it passed da speed b4 startin da check ;D

as 4 trigs

2 trigs

1
condition filed : speed heliname > 5
activision : abovespeed = true

2
condition field : speed heliname > 5 and abovespeed
activision : wateva

LCD OUT

"guess being the community has downsides .." - cheetah
Help Perfecting Da Next Best Thing - O-Team Beta

Offline Burn

  • Members
  • *
Re:speed
« Reply #4 on: 28 Jan 2004, 11:21:07 »
Johan Gustafsson's Scripting Tutorial v2.0. There should be a script in there that does exactly what u want :cheers:

Piraneous

  • Guest
Re:speed
« Reply #5 on: 28 Jan 2004, 11:29:48 »
ok cool,  i used 2 triggers,  one that sets above speed when the heli's speed is above 5 and one that sets my variable to true when it slows below 5.

now for the next trick,  when the heli goes below 5,  its height is set to 4,  i want the squad in the back to jump out of the helicopter without it landing fully.  at the moment,  as soon as my bailout variable is set, the choper tries to land to let the guys out.

i'm sure this is a somewhat harder script to write. i'm hoping to avoid having to do somethign like an old rapeling script i downloaded a few years ago.

Piraneous

  • Guest
Re:speed
« Reply #6 on: 28 Jan 2004, 12:14:42 »
wait out,  i can just get them to eject,  that works.

thanks for you help guys