Arched 1 Posted April 22, 2014 Hi there I'd like some help on a HALO Jump I want to make. All I need is my squad to jump from a C-17 during a mission. (Not in the beginning) I found cobra4v320's script. I found it fucking perfect and tried it for myself. I couldn't really make it work on my mission. I tried merging the script I already had(its not mine tho) with the functions in cobra's script. This is what I tried _group = _this select 0; _vehicle = _this select 1; if ( (typename _group != "GROUP") or (typename _vehicle != "OBJECT") ) exitwith { hintSilent "Invalid Parameters parsed"; }; sleep 1; { unassignvehicle _x; _x action ["EJECT", _vehicle]; sleep 0.5; } foreach units _group; if (_chemLight) then { [_chemLight,_unit] spawn { private ["_chemlight","_unit","_light"]; _chemLight = _this select 0; _unit = _this select 1; _light = "chemlight_red" createVehicle [0,0,0]; if (headgear _unit != "") then { _light attachTo [_unit,[-0.07,0.1,0.25],"head"]; _light setVectorDirAndUp [[0,1,-1],[0,1,0.6]]; } else { _light attachTo [_unit,[0,-0.07,0.06],"LeftShoulder"]; }; waitUntil {animationState _unit == "para_pilot"}; if (headgear _unit != "") then { _light attachTo [vehicle _unit,[0,0.14,0.84],"head"]; _light setVectorDirAndUp [[0,1,-1],[0,1,0.6]]; } else { _light attachTo [vehicle _unit,[-0.13,-0.09,0.56],"LeftShoulder"]; _light setVectorDirAndUp [[0,0,1],[0,1,0]]; }; waitUntil {isTouchingGround _unit || (getPos _unit select 2) < 1}; detach _light; deleteVehicle _light; }; }; if (_saveLoadOut && !isNull (unitBackpack _unit) && (backpack _unit) != "b_parachute") then { private ["_pack","_class","_magazines","_weapons","_items","_helmet"]; _pack = unitBackpack _unit; _class = typeOf _pack; _magazines = getMagazineCargo _pack; _weapons = getWeaponCargo _pack; _items = getItemCargo _pack; _helmet = headgear _unit; removeBackpack _unit; _unit addBackpack "b_parachute"; [_unit,_class,_magazines,_weapons,_items,_helmet,_altitude] spawn { private ["_unit","_class","_magazines","_weapons","_items","_helmet","_altitude"]; _unit = _this select 0; _class = _this select 1; _magazines = _this select 2; _weapons = _this select 3; _items = _this select 4; _helmet = _this select 5; _altitude = _this select 6; private "_packHolder"; _packHolder = createVehicle ["groundWeaponHolder", [0,0,0], [], 0, "can_collide"]; _packHolder addBackpackCargoGlobal [_class, 1]; waitUntil {animationState _unit == "HaloFreeFall_non"}; _packHolder attachTo [_unit,[-0.12,-0.02,-.74],"pelvis"]; _packHolder setVectorDirAndUp [[0,-1,-0.05],[0,0,-1]]; waitUntil {animationState _unit == "para_pilot"}; _packHolder attachTo [vehicle _unit,[-0.07,0.67,-0.13],"pelvis"]; _packHolder setVectorDirAndUp [[0,-0.2,-1],[0,1,0]]; waitUntil {isTouchingGround _unit || (getPos _unit select 2) < 1}; detach _packHolder; deleteVehicle _packHolder; _unit addBackpack _class; clearAllItemsFromBackpack _unit; //clear all gear from new backpack if (_altitude > 3040 && _helmet != "" && _helmet != "H_CrewHelmetHeli_B") then {(unitBackpack _unit) addItemCargoGlobal [_helmet, 1]}; for "_i" from 0 to (count (_magazines select 0) - 1) do { (unitBackpack _unit) addMagazineCargoGlobal [(_magazines select 0) select _i,(_magazines select 1) select _i]; }; for "_i" from 0 to (count (_weapons select 0) - 1) do { (unitBackpack _unit) addWeaponCargoGlobal [(_weapons select 0) select _i,(_weapons select 1) select _i]; }; for "_i" from 0 to (count (_items select 0) - 1) do { (unitBackpack _unit) addItemCargoGlobal [(_items select 0) select _i,(_items select 1) select _i]; }; }; } else { if ((backpack _unit) != "b_parachute") then {_unit addBackpack "B_parachute"}; }; if (_altitude > 3040 && (headgear _unit) != "H_CrewHelmetHeli_B") then {_unit addHeadgear "H_CrewHelmetHeli_B"}; _unit setPos [(getPos _unit select 0), (getPos _unit select 1), _altitude]; if (!isPlayer _unit) then { _unit allowDamage FALSE; //god mode :) _unit switchMove "HaloFreeFall_non"; //place the AI into the free fall animation _unit disableAI "ANIM"; //disable the AI animation so they cant switch back to standing }; if (isPlayer _unit) then { [_unit,_autoOpen] spawn { private ["_unit","_autoOpen"]; _unit = _this select 0; _autoOpen = _this select 1; if (_autoOpen) then { waitUntil {(getPos _unit select 2) < 150 || animationState _unit == "para_pilot" && alive _unit}; _unit action ["OpenParachute", _unit]; //open parachute if 150m above ground }; waitUntil {animationState _unit == "para_pilot"}; // Parachute opening effect for more immersion playSound "open_chute"; //play chute opening sound setAperture 0.05; setAperture -1; "DynamicBlur" ppEffectEnable true; "DynamicBlur" ppEffectAdjust [8.0]; "DynamicBlur" ppEffectCommit 0.01; sleep 1; "DynamicBlur" ppEffectAdjust [0.0]; "DynamicBlur" ppEffectCommit 3; sleep 3; "DynamicBlur" ppEffectEnable false; "RadialBlur" ppEffectAdjust [0.0, 0.0, 0.0, 0.0]; "RadialBlur" ppEffectCommit 1.0; "RadialBlur" ppEffectEnable false; while {(getPos _unit select 2) > 2} do { playSound "para_pilot"; sleep 4.2; }; }; }; [_unit] spawn { private "_unit"; _unit = _this select 0; waitUntil {isTouchingGround _unit || (getPos _unit select 2) < 1 && alive _unit}; if (!isPlayer _unit) then { _unit enableAI "ANIM"; _unit setPos [(getPos _unit select 0), (getPos _unit select 1), 0]; _unit setVelocity [0,0,0]; _unit setVectorUp [0,0,1]; sleep 1; _unit allowDamage TRUE; } else { playSound "close_chute"; cutText ["", "BLACK FADED", 999]; sleep 2; cutText ["", "BLACK IN", 2]; _unit setDamage 0; }; }; But still, All my it did was eject the group from the plane, so Only the first lines of code work. I have no idea how to make my group and me jump with those functions applied. I couldn't find any help anywhere, any help is appreciated Thanks in advance Share this post Link to post Share on other sites
cobra4v320 27 Posted April 23, 2014 Its because you are missing the rest of the parameters at the beginning of your script. How exactly are you calling this script? Share this post Link to post Share on other sites