Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- kh_mauleOffset = [0, 3, 0];
- kh_checkMaule =
- {
- private ["_vehicle", "_menNearProp"];
- _vehicle = _this;
- if (isEngineOn _vehicle) then
- {
- _menNearProp = (_vehicle modelToWorld kh_mauleOffset) nearObjects ["Man", 2.8];
- {
- // Now that setDamage only happens on the local machine (to avoid
- // upsetting BattlEye), only call the prophit once since otherwise
- // "alive" will be true for the victim for many iterations and the
- // sound and other effects will be repeated.
- if (isNil { _x getVariable "kh_hitByMaule" }) then
- {
- _x setVariable ["kh_hitByMaule", true];
- private "_spawned";
- _spawned = [_x, _vehicle] execVM "\khr\maule\scripts\maule_prophit.sqf";
- };
- } forEach _menNearProp;
- };
- };
- if (!isDedicated) then
- {
- [] execVM "fixes\maule\scripts\maule_prophit_monitor.sqf";
- };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement