ACE3/addons/bft_drawing/functions/fnc_doBFTDraw.sqf
2016-09-03 09:35:37 +02:00

23 lines
510 B
Plaintext

#include "script_component.hpp"
disableSerialization;
params ["_map"];
if (isNull _map) exitWith {};
// event handlers for each map
{
_map ctrlAddEventhandler _x;
} forEach [
["KeyDown",FUNC(KeyDown)],
["KeyUp",FUNC(KeyUp)],
["MouseButtonDown",FUNC(MouseButtonDown)],
["MouseButtonUp",FUNC(MouseButtonUp)],
["MouseMoving",{GVAR(mousepos)=[_this select 1,_this select 2];}],
["MouseHolding",{GVAR(mousepos)=[_this select 1,_this select 2];}],
["Draw",FUNC(mapDraw)]
];
true