OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: SharkDog on 27 Apr 2003, 11:39:41
-
Hi all, what is the explosion with the samllest damage?
Is it shell73?
thanks,
Me
-
I use 'RPG' or 'RPG2' or something like that. Been a while.
-
Well since it is for an flak script of the planes in the air with a script, but sometimes the plane explodes of the explosions, so i need explosions that actuall never do damage.
-
hmm nobody knows :(
-
I've done something similar to this in the past...
Instead of having an explosion that did no damage, I just checked the placement of the explosion (before I actually set it off ;)). If the position was too close to the aircraft, I re-chose the position.
Try posting the script you're using and we'll see if we can modify it to suit...
-
Hey
hmm......I could use this script and put it on the vehical getting blowen up:
#loop
driverguy setdammage 0
~0.5
? cusceneover == 1 : exit
goto "loop"
Dunno if it workds though ;)
O neil ;)
-
Wait a second i'll post the script.
As you can see the command line is this: [150,10,blackhawk,log1,"shell73"] exec "flak.sqs"
so thats why i was wondering if there were explosions with less damagage then the shell73
or maby you know how to alter the script so the explosions don't hit the plane.
;
;Created by Pica
;
;area of flak around target
;random height of flak
;target aircraft
;game logic name
;ammo to use
;example
;[150,10,blackhawk,log1,"shell73"] exec "flak.sqs"
_area = _this select 0
_height = _this select 1
_target = _this select 2
_logic = _this select 3
_ord = _this select 4
#loop
_where = getpos _target
_logic setpos [(_where select 0) - random _area + random _area, (_where select 1) - random _area + random _area, (_where select 2) + random _height +10]
_bomb = _ord camcreate getpos _logic
_bomb = _ord camcreate getpos _logic
~random 2.5
;you can change the condition below the end
? alive _target : goto "loop"
-
Hmm... I'm not too sure if this will work with a game logic, but try inserting this line here:
...
_where = getpos _target
_logic setpos [(_where select 0) - random _area + random _area, (_where select 1) - random _area + random _area, (_where select 2) + random _height +10]
? (_target distance _logic < 20): goto "loop"
_bomb = _ord camcreate getpos _logic
...
And see if that works...
If not, we'll find a work around ;)
-
LOL OMG, Sui you just made the best artillery script ever!:D :D :D
Ok so anyways now the explosions fall on the ground, like artillery but they need to be in the air around the airplane.
And I really mean that about that artillery :D but maby i changed it wrong.
here is the script.
;
;Created by Pica
;
;area of flak around target
;random height of flak
;target aircraft
;game logic name
;ammo to use
;example
;[150,10,blackhawk,log1,"shell73"] exec "flak.sqs"
_area = _this select 0
_height = _this select 1
_target = _this select 2
_logic = _this select 3
_ord = _this select 4
#loop
_where = getpos _target
_logic setpos [(_where select 0) - random _area + random _area, (_where select 1) - random _area + random _area, (_where select 2) + random _height +10]
? (_target distance _logic < 20): goto "loop"
_bomb = _ord camcreate getpos _logic
~random 2.5
;you can change the condition below the end
? alive _target : goto "loop"
-
Just put the second:
_bomb = _ord camcreate getpos _logic
line back in...
There need to be two of them created, so they hit each other and explode.
Otherwise (as you've seen) they will fall to the ground instead ;)
-
OMG it works perfectly now thanks sui.
cheers! :D