oksman 37 Posted April 26, 2014 Right I've noticed that people tend to drop their weapons into a WeaponHolder when they die. This means that my gear script won't be able to track what sort of weapon was carried in the primary weapon slot. I've tried some simple nearestObject/NearestObjects without any luck, this is all located into an eventHandler that checks if the player is killed. When killed it launches my script which extracts all the gear and the weapon to the respawn box. This means that the rest of the gear on the body is removed to avoid looting as the mission this is used on is based on cash from waves and something else irrelevant. My true question would be the use of NearestObject/NearestObjects upon death to find this weaponholder and take it's weapon content and move it to the box. Moving it to the box is a small issue that is dependant on knowing the classname of the weapon and where it is, so that's my main concern! Does any of you have any idea how to counter this new feature in A3? Help me find the missing WeaponHolder, cheers :) Share this post Link to post Share on other sites
das attorney 858 Posted April 26, 2014 Hi Oksman, I would try spawn a script from within the code in the EH with a short sleep in it, and then the check for the WH (in case the weapon holder hasn't spawned as soon as the EH runs). Also, try looking for "WeaponHolderSimulated" as well. They're the physics enabled ones that allow weapons to spin about when they are dropped. Share this post Link to post Share on other sites
ffur2007slx2_5 11 Posted April 26, 2014 (edited) Match the index with each killed entity. private ["_All"]; _All = []; { if (typeof _x in ["WeaponHolderSimulated","WeaponHolder"]) then { _All set [count _All,[ getweaponcargo _x, getmagazinecargo _x, getbackpackcargo _x, getitemcargo _x ]]; }; } forEach Vehicles; Edited April 27, 2014 by ffur2007slx2_5 Share this post Link to post Share on other sites
oksman 37 Posted April 27, 2014 Cheers guys. I'll give it a test! Share this post Link to post Share on other sites