gizz46 28 Posted November 25, 2013 Hi Im'm working on a mod/script lately and I want to use the displayAddEventHandler MousebuttonDown. unfortunately I can't use it, because whenn I attach my action to it, the standart action (firing your weapon) is still performed. My question is, is this a bug or is this an intended behaviour? I tested my script with Arma 2 also, and it doesn't work there neither. There is already a ticket on the arma3 feedback tracker, so I guess it is a Bug. http://feedback.arma3.com/view.php?id=10766 So please BI fix this as soon as possible sample script sleep 0.5; (findDisplay 46) displayAddEventHandler ["MouseButtonDown", "_this call KeyMyBlaDown"]; (findDisplay 46) displayAddEventHandler ["KeyDown", "_this call KeyMyPupsDown"]; (findDisplay 46) displayAddEventHandler ["KeyUp", "_this call KeyMyPupsUp"]; BUTTON = false; KeyMyPupsDown = { private['_handled']; _handled = false; _Key =_this select 0; switch (_this select 1) do { case 16: { BUTTON = true; _handled = true; }; }; _handled; }; KeyMyPupsUp = { private['_handled']; _handled = false; _Key =_this select 0; switch (_this select 1) do { case 16: { BUTTON = false; _handled = true; }; }; _handled; }; KeyMyBlaDown = { private['_handled']; _handled = false; _Key =_this select 0; if (BUTTON) then { switch (_this select 1) do { case 0: { hint "yo";_handled = true;}; }; }; _handled; }; Share this post Link to post Share on other sites
7mary3 10 Posted November 26, 2013 I've had problems with trying to change the mouse in other games as well. I was told on one that the mouse was "hardcoded in" and really couldn't be changed. This might be a similar situation. Share this post Link to post Share on other sites
adanteh 58 Posted November 27, 2013 Can't you return false? That should normally disable the normal action. Share this post Link to post Share on other sites
gizz46 28 Posted November 27, 2013 @Adanteh can you show me what you mean exactly ? I tried it so far, doesn't work either Share this post Link to post Share on other sites
sakura_chan 9 Posted November 28, 2013 Can't you return false? That should normally disable the normal action. That only works on the keyboard, not the mouse or joystick, unfortunately. Share this post Link to post Share on other sites
l etranger 5 Posted November 28, 2013 Yep, only work on keyboard input. Would be cool have ability to lock mousewheel menu and camera rotation. Share this post Link to post Share on other sites