OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: NoMore on 25 Jul 2009, 13:28:05
-
Ok, I'm making a rescue mission where the player is sitting in the Rescue Raft from FDFmod. He is sitting in the cargo and it is important that he cannot use the action "To driver's seat".
It is also important that he can get out of the raft and the get in the cargo again still without entering the driver's seat.
Is this possible? ???
NoMore
-
Take a look at the Get In event handler. That combined with unAssignVehicle should do what you need. :good:
-
I'm sorry but I'm not really good at scrips though I understand the basics. :confused:
Can you please explain what you mean? I checked the Bohemia Interactive Wiki but still don't understand...
Thank you for such quick answer. :)
NoMore
-
See attached missionette.
-
As long as no-one else has to get into the driver's seat ... (and even then it would be possible with some scripting) ...
Make sure the empty lifeboat is named, say hellosailor.
Then just place a GameLogic (side: Game Logic ---> Objects ---> GameLogic) and write in the init line:this moveInDriver hellosailor
Game Logics - your invisible friends!
-
If you only want your player or the guy who is hurt not to enter as driver ,you will need a checking trigger.
Put these in the trigger.
axis a /b : 0
activation : Any body
Repeatedly
Not present
type : none
Condition : nameofguy == driver nameofvehicle
On Activation :nameofguy action ["eject",nameofvehicle]
I think this one will work(it worked for me)
Everytime you (as player) entered the vehicle,then he will be pumped out from the seat.
If you want to use with AI,please do the following,
On the init line of the vehicle,type :
nameofguy assignascargo nameofvehicle
Remove the get in waypoint (if you have one) and place a "move" WP near the vehicle.
In the On Activation of the WP,type :
nameofguy ordergetin true
I think that solves your problem
Haroon1992..............
-
Thank you so much every one!
I think Walter's way is the easiest though. I didn't even know you could use game logics like that..
Must remember to look at a game logic tutorial some time. ;)
NoMore