To some extent, the following has alredy been said. I'm just rephrasing it so as to increase the understanding and recognition of the problems:
SummaryThe problems with AI:s and vehicle mounting/disembarkation in MP is one of the most annoying bugs of OFP. Here's the deal:
You can't order your guys to disembark from a vehicle unless that vehicle
is local to your computer. What does that mean? For a MP mission on a dedicated server it means that the trouble appears when the vehicle is either driven by an AI or another player.
In other words - if another player or another AI (not under your control) is the driver of a vehicle and you have your guys in cargo in said vehicle - you're boned.
"Solutions" to the disembarkation problem in MPIf it's another player, tell him to hover the heli just above ground or drive the truck
slowly forward. Then, you can order your AI:s to
EJECT instead of telling them to disembark.
If the vehicle is driven by an AI and has decided to land or stop...tough luck :-) In these cases, that driver frequently catches a "stray" bullet from some of the players in irritation, thereby fixing the problem. That trick is unavailable if you are riding in the back of a BMP, for example... D-oh!
Embarkation and "CAN'T GET THERE"Oh how we love this...NOT. When you order your guys in, they tell you they can't. The trick here, however is to just wait it out - often, they will eventually get in the vehicle anyway.
Scripting "EJECT" and "GETOUT"/"GET OUT" actionsThere is but one rule here and it has no ifs, buts or exceptions:
The action command should be issued on the machine where the affected unit is local and only there.local? What's "local"?The term comes from the OFP script command
local. Please look it up in the command reference and acquaint yourself with it. Every unit in a MP game is "local" to one of the participating computers (server and clients). Being local to a machine means that computer controls it. For example:
- the soldier you control is local to your computer, obviously.
- Any AI:s under your command are also local to your computer.
- AI:s not controlled by any players will be local to the server
- A vehicle is local to the machine where the driver of that vehicle is local.
- If you host a MP game, you act as both a client and a server.
- Therefore, your squad and all other AI:s except the ones controlled by other players are local to your machine.
- On the other hand if you play on a dedicated server, all non-player AI:s are local to the server, of course.
I hope that helps to shine more light on this
highly annoying issue. There are tricks to work around it though:
* One can add a "Disembark my guys" action to certain vehicles or the player so you can force-disembark your guys from any vehicle.
* Make sure automated insertion/ejection scripts run on all machines. Then, before issuing an
action, check if the affected unit is local. Take this example, showing part of an ejection script:
_units=units SomeGroup
_c=count _units
_i=0
#loop
~0.5
_dude=_units select _i
?local _dude: _dude action ["EJECT",vehicle _dude]
_i=_i+1
? _i<_c : goto "loop"
Due to the brokenness of OFP, proper MP programming involves lots of trickery, one of which is usage of the
local command.