OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: Spliff air on 23 Aug 2002, 14:15:34
-
Does anyone have a flak script because i want one 4 me airborne campaighn
-
There were LOADS of threads and post on Flak and AA fire in the old forums - I imagine once the site is up and running you'll be able to find something either in the Addons depot or the FAQ section :D
Dan ;D
-
Well, it's my understanding that everything apart from the forum is saved somewhere, and that code snippets, tutorials and so on will be coming back online.
I assume that there are some Flak scripts among those code snippets (God knows there are a lot of them)
-
One of our Community members over at http://thecorps.insideofp.com forums has posted a nice flak script in the scripts section. Check it out.
Hope, I'm not cutting OFPEC grass here.... just wanting to help someone and not going to post it here without author's permission.
-
Another Johan Gustafson special...
Cut and paste.
_Actor = _this select 0
_Centre = _this select 1
_area = _this select 2
_minZ = _this select 3
_maxZ = _this select 4
_freq = _this select 5
_rounds = _this select 6
; Get the old positions for the detonator object
_ActorPos = GetPos _Actor
_oldx = _ActorPos select 0
_oldy = _ActorPos select 1
_oldz = _ActorPos select 2
; Get the centre point positions, once!
_CentrePos = GetMarkerPos _Centre
_cx = _CentrePos select 0
_cy = _CentrePos select 1
; Prepare some values
_areaX2 = _area * 2
_value = (_maxZ - _minZ) * 2
#Update
_rounds = _rounds - 1
; Move the detonator to some random location
_Actor SetPos [_cx + Random(_areaX2) - _area,_cy + Random(_areaX2) - _area, Random(_value) + _minZ]
; Detonate the detonater
_Actor SetDammage 1
; Wait a milli second
~0.01
; Move back the detonater
_Actor SetPos [_oldx,_oldy,_oldz]
_Actor SetDammage 0
~_freq
? (_rounds > 0) : goto "Update"
exit
Should Work for ya.
YT.
-
kinda seems to me that insideofp.com is down right now or something...??
-
did u no that if ya camcreate 2 charges in the same pace at the sme hight they explode tada
-
did u no that if ya camcreate 2 charges in the same pace at the sme hight they explode tada
Could you give the example of the camcreate for this? Newbie but have seen "camcreate" used lots around the forum but no syntax - newbie to this site ???
-
well im no expert by any strech of the imagination so if u wanta quick answer u should ask a pro (even tho this stuff is pretty easy) *mutters sumthing about ts camcreate...... befor running off into the distance* if no1 will help u pm me and ill explain it to ya ;)