OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: The-Architect on 14 Mar 2005, 02:28:28
-
I was sure that there was a script out there that did this but I can't find it. I'm going to put it up as an idea here instead.
Here's the deal.
I want a script that will let me get into an enemy vehicle and become a captive (setcaptive true), I want to be able to drive the vehicle about and have radio chatter audible from inside.
If I get out of the vehicle obviously the chat would stop and I'd no longer be captive. Also, If possible, I'd like it so that if I got within a certain distance of an enemy player I'd no longer be captive. As if he'd seen that I was a bad guy. Another thing that would switch me from setcaptive true to false would be if I fired a gun from the vehicle, like machinegun.
Possible?
-
Basic bones of script :
_vehicle = _this select 0
#start
?(driver _vehicle == player):GOTO "safe"
~5
goto "start"
#safe
player setcaptive true
car say "radioClass"
goto "start"
That works best if the radio stuff is 5 seconds long, and a loop.. Change ~5 to a better lenght
Like I said, jsut bones of script
- Ben