OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: Nemesis6 on 08 Mar 2005, 22:21:08

Title: Keeping pilots from ejecting
Post by: Nemesis6 on 08 Mar 2005, 22:21:08
I've tried a lot of things to keep pilots from ejecting when their aircraft gets a curtain ammount of damage, nothing have worked. Now I'll ask here... can anyone help me with this?
Title: Re:Keeping pilots from ejecting
Post by: bedges on 08 Mar 2005, 22:50:24
question is, why do you want them to do what they would do normally in reality? loons are sometimes idiots, but rarely suicidal.

you want them to go down with the chopper? create a script which deletes the pilot and gunner when the chopper in question gets to that non-flyable stage. presto. no parachutes, just one broken chopper. splat. :)

EDIT - better yet, use a trigger, as there doesn't seem to be an event handler for damaged vehicles, only loons.
Title: Re:Keeping pilots from ejecting
Post by: Flauta on 08 Mar 2005, 23:03:15
well, I thoght when the pilots auto-Eject themselves, is because the Chopper/Plane Suddenly Shut-off, if you try to start them again you cant, thats because it got a Engine Dammage or something... but what you are looking for is to wach your chopper fall whit the pilot inside... no idea  :-\
ave you tryed whit MoveinDriver command?
something like these:
Code: [Select]

_chopper = this select 0
_Gunner = gunner _chopper
_driver = driver _chopper

#begin
? ! (_gunner in _chopper) : goto "Movegunner"
? ! (_driver in _chopper) : goto "Movedriver"
? ! (alive _gunner) and ! (alive _driver) : goto "exit"
? ! (alive _chopper) : goto "exit"
~0.025

goto "begin"

#Movegunner
_gunner moveingunner _chopper
goto "begin"

#movedriver
_driver moveindriver _chopper
goto "begin"

#exit
exit

What you think?
im not experienced on scripts.. but i think this will work.. if it is possible to "moveinriver"/"moveingunner" when the Helo is deactivated...

Salute!
Title: Re:Keeping pilots from ejecting
Post by: Nemesis6 on 09 Mar 2005, 19:48:53
I fixed up the script you made, it works, problem is - the pilot doesn't want to stay there. He keeps ejecting...
Title: Re:Keeping pilots from ejecting
Post by: bedges on 09 Mar 2005, 20:12:33
if you clarify the purpose of what you're trying to achieve, maybe we could be of more help...