Jump to content
Sign in to follow this  
luckyhendrix

Radio Trigger and MP compatibility

Recommended Posts

Hi,

I'm actualy making a coop mission , that requires the leader of the player to activate a trigger via radio ( the 0-0-1 menu). I put this in the On act field of the trigger

nul = [Heli1,Heli2] execVM "Helistart.sqf";

helistart.sqf :

_heli1 = _this select 0;
_heli2 = _this select 1;
{
_x moveincargo _heli1;
}foreach units group P1;

rec = [] spawn Mypath1;

it does not seem to be a very reliable way to do it, as I understand when a plyer calls 0-0-1 it activate the trigger localy on his PC and thus the script does not exec on the sever , where it should. How could I make this work ? :confused:

Share this post


Link to post
Share on other sites

As far as I remember, the trigger should executes on all clients.

So all you need to add is an "isServer"-check.

if (isServer) then {
_heli1 = _this select 0;
_heli2 = _this select 1;
{
	_x moveincargo _heli1;
} forEach units group P1;

rec = [] spawn Mypath1;
};

not 100% sure though. ^^ I rarely use radio-triggers.

Share this post


Link to post
Share on other sites

It didn't work ;( only the leader of the group (who was also the one hosting the server) got transfered to the chopper

Share this post


Link to post
Share on other sites

Hmm, that doesn't make sense. If it works for the leader, it should work for the others aswell.

The effects of moveInCargo are global.

Share this post


Link to post
Share on other sites

Yes , I really can't figure out why it didn't work. the script executed on the server , so everyone should be transfered to heli1.Anyway, I used a work around , each player use an addaction to transfer themself in the chopper then the leader starts the flight sequence.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×