OFPEC Forum

Editors Depot - Mission Editing and Scripting => ArmA - Editing/Scripting General => Topic started by: gambla on 16 Oct 2008, 17:27:14

Title: Crew to leave vehicle by trigger
Post by: gambla on 16 Oct 2008, 17:27:14
Hi,
i've a group of vehicles and like to have the crew disembark with a trigger. Any way to do this without waypoints ?

thank you very much ! :)

Title: Re: Crew to leave vehicle by trigger
Post by: Luke on 17 Oct 2008, 01:38:45
in an .sqf file try the following:

Code: (Exit.sqf) [Select]
_vehiicle = _this select 0;
_crew= crew _vehicle;
_pos= _vehicle modeltoworld [1,3,0];
{_x setpos _pos} foreach _crew;

Put Exit.sqf in the folder of your mission.

Call it in a trigger using:
Code: [Select]
[vehicle] execvm "exit.sqf";
replacing "vehicle" with the vehicle of your choosing.

Luke
Title: Re: Crew to leave vehicle by trigger
Post by: h- on 17 Oct 2008, 08:55:00
- create a trigger, the size you need it to be (make sure the whole group fits in it)
- in it's on act. field write:
Code: [Select]
{(group _x) leaveVehicle _x} forEach thislist- group the trigger with the group and set it to be activated by 'whole group'
Title: Re: Crew to leave vehicle by trigger
Post by: gambla on 21 Oct 2008, 13:01:47
thanks guys, will try it asap :)