2015-01-12 09:48:26 +00:00
|
|
|
/*
|
2015-02-02 08:35:17 +00:00
|
|
|
* Author: Garth 'L-H' de Wet
|
|
|
|
* Initialises the player object for the explosive system.
|
|
|
|
*
|
|
|
|
* Arguments:
|
|
|
|
* None
|
|
|
|
*
|
|
|
|
* Return Value:
|
|
|
|
* None
|
|
|
|
*
|
|
|
|
* Example:
|
|
|
|
* None
|
|
|
|
*
|
|
|
|
* Public: No
|
|
|
|
*/
|
2015-01-12 09:48:26 +00:00
|
|
|
#include "script_component.hpp"
|
2015-05-21 22:47:54 +00:00
|
|
|
|
2015-05-27 19:09:06 +00:00
|
|
|
if !(hasInterface) exitWith {};
|
2015-05-21 22:47:54 +00:00
|
|
|
|
2015-05-27 19:09:06 +00:00
|
|
|
["interactMenuOpened", {_this call FUNC(interactEH)}] call EFUNC(common,addEventHandler);
|
2015-05-21 22:47:54 +00:00
|
|
|
|
2015-01-12 09:48:26 +00:00
|
|
|
GVAR(PlacedCount) = 0;
|
|
|
|
GVAR(Setup) = objNull;
|
|
|
|
GVAR(pfeh_running) = false;
|
2015-02-04 00:16:47 +00:00
|
|
|
GVAR(CurrentSpeedDial) = 0;
|
2015-01-12 09:48:26 +00:00
|
|
|
|
2015-04-09 19:48:27 +00:00
|
|
|
//Cancel placement if interact menu opened
|
|
|
|
["interactMenuOpened", {
|
|
|
|
if (GVAR(pfeh_running) && {!isNull (GVAR(Setup))}) then {
|
|
|
|
call FUNC(place_Cancel)
|
|
|
|
};
|
|
|
|
}] call EFUNC(common,addEventHandler);
|
|
|
|
|
2015-01-12 20:39:37 +00:00
|
|
|
[{(_this select 0) call FUNC(handleScrollWheel);}] call EFUNC(Common,addScrollWheelEventHandler);
|