mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Apply the ufeh to ACE_HuntIr
This commit is contained in:
parent
0b9695ce70
commit
7ace1738c0
@ -9,11 +9,3 @@ class Extended_PostInit_EventHandlers {
|
|||||||
init = QUOTE( call COMPILE_FILE(XEH_postInit) );
|
init = QUOTE( call COMPILE_FILE(XEH_postInit) );
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
class Extended_FiredBIS_EventHandlers {
|
|
||||||
class CAManBase {
|
|
||||||
class ADDON {
|
|
||||||
clientFiredBIS = QUOTE(_this call FUNC(handleFired));
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
@ -7,3 +7,8 @@ GVAR(TI) = 0;
|
|||||||
GVAR(cur_cam) = 0;
|
GVAR(cur_cam) = 0;
|
||||||
GVAR(ROTATE) = 0;
|
GVAR(ROTATE) = 0;
|
||||||
GVAR(ELEVAT) = 0.01;
|
GVAR(ELEVAT) = 0.01;
|
||||||
|
|
||||||
|
// Register fire event handler
|
||||||
|
// Don't run for non players, as they are too dumb to launch huntirs anyway
|
||||||
|
["firedPlayer", DFUNC(handleFired)] call EFUNC(common,addEventHandler);
|
||||||
|
["firedPlayerNonLocal", DFUNC(handleFired)] call EFUNC(common,addEventHandler);
|
||||||
|
@ -1,16 +1,10 @@
|
|||||||
/*
|
/*
|
||||||
* Author: Norrin, Rocko, Ruthberg
|
* Author: Norrin, Rocko, Ruthberg
|
||||||
*
|
*
|
||||||
* Handles HuntIR projectiles
|
* Handles HuntIR projectiles. Called from the unified fired EH for all CAManBase.
|
||||||
*
|
*
|
||||||
* Arguments:
|
* Arguments:
|
||||||
* 0: unit - Object the event handler is assigned to <OBJECT>
|
* None. Parameters inherited from EFUNC(common,firedEH)
|
||||||
* 1: weapon - Fired weapon <STRING>
|
|
||||||
* 2: muzzle - Muzzle that was used <STRING>
|
|
||||||
* 3: mode - Current mode of the fired weapon <STRING>
|
|
||||||
* 4: ammo - Ammo used <STRING>
|
|
||||||
* 5: magazine - magazine name which was used <STRING>
|
|
||||||
* 6: projectile - Object of the projectile that was shot <OBJECT>
|
|
||||||
*
|
*
|
||||||
* Return Value:
|
* Return Value:
|
||||||
* None
|
* None
|
||||||
@ -19,10 +13,13 @@
|
|||||||
*/
|
*/
|
||||||
#include "script_component.hpp"
|
#include "script_component.hpp"
|
||||||
|
|
||||||
params ["_unit", "_weapon", "_muzzle", "_mode", "_ammo", "_magazine", "_projectile"];
|
//IGNORE_PRIVATE_WARNING ["_unit", "_weapon", "_muzzle", "_mode", "_ammo", "_magazine", "_projectile", "_vehicle", "_gunner", "_turret"];
|
||||||
|
TRACE_10("firedEH:",_unit, _weapon, _muzzle, _mode, _ammo, _magazine, _projectile, _vehicle, _gunner, _turret);
|
||||||
|
|
||||||
if (_ammo != "F_HuntIR") exitWith {};
|
if (_ammo != "F_HuntIR") exitWith {};
|
||||||
|
|
||||||
|
if (!hasInterface) exitWith {};
|
||||||
|
|
||||||
[{
|
[{
|
||||||
params ["_projectile"];
|
params ["_projectile"];
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user