Home   Help Search Login Register  

Author Topic: Carbombs with camcreated LGBs.  (Read 678 times)

0 Members and 1 Guest are viewing this topic.

Milwot

  • Guest
Carbombs with camcreated LGBs.
« on: 24 Nov 2003, 04:29:36 »
Is there a simple script for camcreating a laserguidedbomb where ever a truck is parked using the radio command? I know it's simple but at the moment it escapes me...

Offline General Barron

  • Former Staff
  • ****
  • Semper Fi!
Re:Carbombs with camcreated LGBs.
« Reply #1 on: 24 Nov 2003, 05:22:50 »
Put this in the activation field of the radio trigger:

bomb = "LaserGuidedBomb" camcreate getpos TargetTruck

And name the car you want it to appear in "TargetTruck".
HANDSIGNALS COMMAND SYSTEM-- A realistic squad-control modification for OFP
kexp.org-- The best radio station in the world, right here at home! Listen to John Richards!

Grendel

  • Guest
Re:Carbombs with camcreated LGBs.
« Reply #2 on: 24 Nov 2003, 05:39:18 »
Here you go:

Place a trigger activated by a radio channel with the following in the 'on activation' field: [truckname] exec "carbomb.sqs"

Code: [Select]
;Carbomb Script
;_delay is the number of seconds before the bomb explodes

_truck=_this select 0
_delay=10

hint "Bomb Activated"

#delay
~1
_delay=_delay-1
?(_delay>0):goto "delay"

_tpos=getpos _truck
_tpx=_tpos select 0
_tpy=_tpos select 1

"laserguidedbomb" camcreate [_tpx,_tpy,0]
exit
Syntax not guaranteed, but it should work.

-Grendel

Offline General Barron

  • Former Staff
  • ****
  • Semper Fi!
Re:Carbombs with camcreated LGBs.
« Reply #3 on: 24 Nov 2003, 06:01:01 »
Quote
#delay
~1
_delay=_delay-1
?(_delay>0):goto "delay"

Or you could just type this:

~_delay

But anyway, you could still use my trigger if you wanted a delay. Just change the "min" "max" and "mid" fields of the trigger to the delay you want.
HANDSIGNALS COMMAND SYSTEM-- A realistic squad-control modification for OFP
kexp.org-- The best radio station in the world, right here at home! Listen to John Richards!