ACE3/addons/nightvision/XEH_postInitClient.sqf

38 lines
1.7 KiB
Plaintext
Raw Normal View History

2015-01-12 22:08:37 +00:00
// by commy2
#include "script_component.hpp"
if (!hasInterface) exitWith {};
GVAR(ppEffectBlur) = ppEffectCreate ["dynamicBlur", 1234];
2015-01-12 22:08:37 +00:00
GVAR(ppEffectBlur) ppEffectForceInNVG true;
GVAR(ppEffectBlur) ppEffectAdjust [0];
GVAR(ppEffectBlur) ppEffectCommit 0;
2015-01-12 22:08:37 +00:00
GVAR(ppEffectRadialBlur) = ppEffectCreate ["radialBlur", 1238];
GVAR(ppEffectRadialBlur) ppEffectForceInNVG true;
GVAR(ppEffectRadialBlur) ppEffectAdjust [0, 0, 0, 0];
GVAR(ppEffectRadialBlur) ppEffectCommit 0;
GVAR(ppEffectFilmGrain) = ppEffectCreate ["FilmGrain", 1235];
GVAR(ppEffectFilmGrain) ppEffectAdjust [0.25, 2.5, 2.5, 2.5*0.3, 2.5*0.3, false];
GVAR(ppEffectFilmGrain) ppEffectCommit 0;
GVAR(ppEffectNVGBrightness) = ppEffectCreate ["ColorCorrections", 1236];
GVAR(ppEffectNVGBrightness) ppEffectForceInNVG true;
GVAR(ppEffectNVGBrightness) ppEffectAdjust [1, 1, 0, [0, 0, 0, 0], [0, 0, 0, 1], [0, 0, 0, 1]];
GVAR(ppEffectNVGBrightness) ppEffectCommit 0;
GVAR(ppEffectMuzzleFlash) = ppEffectCreate ["ColorCorrections", 1237];
GVAR(ppEffectMuzzleFlash) ppEffectEnable true;
GVAR(ppEffectMuzzleFlash) ppEffectForceInNVG true;
GVAR(ppEffectMuzzleFlash) ppEffectAdjust [1, 1, 0, [0, 0, 0, 0], [0, 0, 0, 1], [0, 0, 0, 1]];
GVAR(ppEffectMuzzleFlash) ppEffectCommit 0;
// Setup the event handlers
["playerInventoryChanged", FUNC(updatePPEffects)] call EFUNC(common,addEventHandler);
["playerVisionModeChanged", FUNC(updatePPEffects)] call EFUNC(common,addEventHandler);
["zeusDisplayChanged", FUNC(updatePPEffects)] call EFUNC(common,addEventHandler);
["cameraViewChanged", FUNC(updatePPEffects)] call EFUNC(common,addEventHandler);
["playerVehicleChanged", FUNC(updatePPEffects)] call EFUNC(common,addEventHandler);
["playerTurretChanged", FUNC(updatePPEffects)] call EFUNC(common,addEventHandler);