OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: penguinman on 19 Mar 2005, 04:47:07
-
is there any way to make a script that if a paratrooper is over trees or a forrest, then if he hits a tree the parachute will be stuck in a setpos loop where it first hit the tree.
then the player gets an action"cut harnes" and when he activates it it takes a few secconds and then he drops out of his parachute and falls to the ground, better not use cut if hes too high up.
you could use getspeed to see if the parachute has gone to getspeed _para ? < 3 : posloop
his speed will go below 3 when he hits the tree and he will then get stuck
-
maybe if you put triggers over all of the forests then you could detect height
bit tiresome but it could work
-
no this would be simple simply use this file ([man] exec "Paracheck.sqs") on every dude who gets stuck in trees
_unit = _this select 0
@(velocity _unit select 2 > -4)
_unit setpos [(getpos _unit select 0),(getpos _unit select 1),0]
exit
It will be a big jerk but you could easily fix the problem with a loop and getpos, but I don't feel like typing all that in right now... :P
-
well, thanks for trying but it dosent work really,
could sombody expand on his idea, or rijik plz finish it.
-
i tried doing this but it didnt seem to work i had a paradrop script from a chopper and timed how long it takes you to get from the chopper tho the tree height and then i ran another script with a hint saying you go stuck in teh tree and setpositioning the player about 2 metres of the grounf then added a action called cut parachute and then i played an animation then set positioned him to the grounf.
i dunno why but he kept falling over and dying
-
really?
wow, could i have it.
i actualy wanted him to die if he falls from to high up so dont worry about the setpos,
I just want the para getting stuck and him getting the action to cut it and if he cuts it then he is right next to the straps and just falls from there so if he is too high when he cuts it then he dies or breaks a leg, if he dosent cut it then i have a script which has his buds come get him down.
thanks
-
yeah sur you can have it as long as if you get it to work i can have a little copy.
i will have to fish it out of my recycle bin. so it will be later on
and by the way its nothing really that specail
-
wow that didnt take long got it
basically one script times how long then set posess him in the tree then adds an action cut then when that is activated it plays hand behind neck anim thenn set poses him back down slowly so im not sure why he died any way hee it is
-
hmm, im not a good scripter how would i remove the setpos down slowly part and just keep everything else
-
in cut.sqs
remove the lines that say off1 setpos
and also dont forget to rename all the off1 with player or whoever you want to get stuck