Jump to content
Sign in to follow this  
evans d [16aa]

Help with a script thanks

Recommended Posts

Hiya guys, I was given this script and it isn't working for me. Can anyone see where it's going wrong?

{
if (_x != driver insertionhelo) then {
	_x joinAsSilent [player];
};
} forEach (crew insertionhelo);

I'm initilizing it in a trigger thusly

null = execVM "pilotsjoinsquad.sqf";

Anyone care to help me out here?

******************************

EDIT:

Issue resolved:

Thanks to "Muzzleflash" for the script.

For others, the script is as follows:

_cargo = crew <VEHICLENAME>;
_cargo = _cargo - [driver <VEHICLE_NAME>];
_cargo joinSilent <GROUP>;

And initilized in a trigger thus

null = execVM "<NAME_OF_SCRIPT>";

Edited by Bashkire

Share this post


Link to post
Share on other sites

According to the BIKI joinAsSilent work this way: http://community.bistudio.com/wiki/joinAsSilent, where you have to give it an array as the right-side argument. Either do this:

_x joinAsSilent [player, 2];

Or this:

[_x] joinSilent player;

Or maybe try this:

_cargo = crew insertionhelo;

_cargo = _cargo - [driver insertionhelo];

_cargo joinSilent player;

Hmm maybe you should name it something else, the filename and the result contradict each other.

Share this post


Link to post
Share on other sites

Thanks, I'll give it a go. I'm only calling it that because the crew are all USMC pilots to make the chopper look more eralistic rather than some randon soldier flying as co-pilot. I see your point, though.:)

---------- Post added at 06:50 PM ---------- Previous post was at 06:08 PM ----------

Works like a dream. Thanks mate!

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  

×