BEAKSBY 11 Posted August 28, 2014 Hi All, How do I pass _gun1 into the "Killed" EH? _gun1 = createVehicle [_vehType, _pos,[], 0, "CAN_COLLIDE"]; _newUnit addeventhandler ["killed",{sleep 0.2; _gun1 setVariable ["ReinforceStaticWeapon_addAction", TRUE, TRUE]; //HOW DO I PASS _gun1 into EH? _allowAddAction = _gun1 getVariable "ReinforceStaticWeapon_addAction"; hint format ["fn_StaticWeaponDrop \n _newUnit ""killed"" EH \n _allowAddAction: %1", _allowAddAction]; }]; ---------- Post added at 23:21 ---------- Previous post was at 22:51 ---------- NEVERMIND, I used vehicle (_this select 0); Share this post Link to post Share on other sites
bangabob 42 Posted August 30, 2014 You could also setvariable the _gun into the _newUnit and retrieve it using getvariable inside the killed EV. Share this post Link to post Share on other sites
BEAKSBY 11 Posted August 30, 2014 You could also setvariable the _gun into the _newUnit and retrieve it using getvariable inside the killed EV. Yup, that works. Thanks again. Share this post Link to post Share on other sites