diff options
| author | hybrid <hybrid@hybridlabs.pro> | 2026-06-11 19:38:09 +0300 |
|---|---|---|
| committer | hybrid <hybrid@hybridlabs.pro> | 2026-06-11 19:38:09 +0300 |
| commit | a3a91d4f45b22fd487ecbc954ad979be5d03efdd (patch) | |
| tree | a554ab159a347dcd6c00ca1c7c26c1ec3ac0a6bd /Client/Module/CM/CM_Spoofing.sqf | |
| download | a2wf_chernarus-main.tar.gz a2wf_chernarus-main.tar.bz2 a2wf_chernarus-main.zip | |
Diffstat (limited to '')
| -rw-r--r-- | Client/Module/CM/CM_Spoofing.sqf | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/Client/Module/CM/CM_Spoofing.sqf b/Client/Module/CM/CM_Spoofing.sqf new file mode 100644 index 0000000..25bb764 --- /dev/null +++ b/Client/Module/CM/CM_Spoofing.sqf @@ -0,0 +1,18 @@ +Private ["_ammo","_chance","_enemy","_prob","_missile","_vehicle"];
+_vehicle = _this select 0;
+_ammo = _this select 1;
+_enemy = _this select 2;
+_missile = objnull;
+
+if ((alive _vehicle) && (isEngineOn _vehicle)) then {
+ _missile = nearestObject [_enemy,_ammo];
+ waitUntil {(_missile distance _vehicle) < ((speed _vehicle) * 1.5)};
+ _prob = 25 + (random 75);
+ _chance = random 100;
+ if (_prob > _chance) then {
+ while {alive _missile} do {
+ _missile setDir ((getDir _missile) + ((random 20) - 10));
+ sleep 0.1;
+ };
+ };
+};
\ No newline at end of file |
