jAMDup 2 Posted March 26, 2016 The vehicle I'm working on has three "weapons", a smoke screen, an M2 .50 cal (Non functional at the moment), and the main armament. This main armament can only work by script, otherwise it doesn't have the desired effect. The problem is I use the "fired" event handler to run the script, and after some testing I found out, when the smoke screen is deployed, it also sets of the main armament. I've looked through the EH page on the wiki and saw nothing of use, which begs the question, is there a work around for this problem? Thanks Share this post Link to post Share on other sites
flyinpenguin 30 Posted March 26, 2016 Reference https://community.bistudio.com/wiki/Arma_3:_Event_Handlers fired will give you some variables you can check to see what is being fired. You can check via weapon, muzzle, or ammo type. Use this to see if it's firing smoke or the correct main armament. 1 Share this post Link to post Share on other sites
jAMDup 2 Posted March 27, 2016 How do I implement the arguments though? Right now I have this: class Eventhandlers { init = "_ok = _this execVM '\ Init File Path'"; fired = "_ok = _this execVM '\main armament'"; }; Thank you! Share this post Link to post Share on other sites
flyinpenguin 30 Posted March 27, 2016 Throw an if statement around the execVM or put the if inside the file you execute for fired. Both have their own benefits being inside config will be more immediate, and inside file will run slightly smoother but slower. Share this post Link to post Share on other sites
jAMDup 2 Posted March 27, 2016 I've deciced on putting the "If" statement in the executed file, but I'm a little confused on the syntax. If (fired..) then{ // What do I use here to check the weapon? }; Sorry, I'm new to using EH. Thank you for the assistance so far. Share this post Link to post Share on other sites
flyinpenguin 30 Posted March 27, 2016 Your config should stay similar, but inside the .sqf you call you should put something like If (_this select 1 isKindOf "main_armament_classname") then { //insert code for firing main armament }; Share this post Link to post Share on other sites
jAMDup 2 Posted March 27, 2016 Perfect, that's what I was looking for. Thank you so much. Share this post Link to post Share on other sites