mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
4e04100ea9
* new reticle for spotting scope * reticle b * illuminated reticle for night * use orig spotting scope reticle, bigger occular * fix spotting scope attenuation
28 lines
786 B
Plaintext
28 lines
786 B
Plaintext
#include "script_component.hpp"
|
|
|
|
ADDON = false;
|
|
|
|
PREP_RECOMPILE_START;
|
|
#include "XEH_PREP.hpp"
|
|
PREP_RECOMPILE_END;
|
|
|
|
["ACE_SpottingScopeObject", "killed", {
|
|
params ["_wreck"];
|
|
|
|
private _tube = "ACE_SpottingScope_tube" createVehicle [0,0,0];
|
|
_tube setDir (getDir _wreck - 180);
|
|
_tube setPosASL AGLToASL (_wreck modelToWorld (_wreck selectionPosition "destructionEffect"));
|
|
_tube setVelocity [1 - random 2, 1 - random 2, 4];
|
|
_tube addTorque (vectorNormalized [1 - random 2, 1 - random 2, 1 - random 2] vectorMultiply 4);
|
|
}] call CBA_fnc_addClassEventHandler;
|
|
|
|
["ACE_SpottingScopeObject", "GetOut", {
|
|
params ["_vehicle", "", "_unit"];
|
|
|
|
if (local _unit) then {
|
|
_unit setDir getDir _vehicle;
|
|
};
|
|
}] call CBA_fnc_addClassEventHandler;
|
|
|
|
ADDON = true;
|