Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Created by νєтι¢υѕ. This is a public source to anyone who wishes to have it
- // This script allows you to restrain and unrestrain a target. Good for military hostage situations and a lot more that anyone could think of.
- //------------------------------------------------------------------------------------------------------------------------------
- // First create a .sqf file called "restrain.sqf". And place the script below into it.
- //------------------------------------------------------------------------------------------------------------------------------
- private ["_Suspect"];
- _Suspect = cursorTarget;
- if (alive _Suspect) then {
- if (!(_Suspect in playableUnits)) exitWith {};
- if (_Suspect distance player > 3 || (!(_Suspect isKindOf "Man"))) exitWith {};
- _Suspect attachTo [player,[0.6,0.3,0]];
- player groupChat "Detained Target";
- };
- //------------------------------------------------------------------------------------------------------------------------------
- // then create another .sqf file called "unrestrain.sqf". And place the script below into it.
- //------------------------------------------------------------------------------------------------------------------------------
- private ["_Suspect"];
- _Suspect = cursorTarget;
- if (alive _Suspect) then {
- if (!(_Suspect in playableUnits)) exitWith {};
- if (_Suspect distance player > 3 || (!(_Suspect isKindOf "Man"))) exitWith {};
- detach _Suspect;
- player groupChat "Undetained Target";
- };
- //------------------------------------------------------------------------------------------------------------------------------
- // This is what you add to you "init.sqf" or whatever addAction array to execute the script(s) above.
- //------------------------------------------------------------------------------------------------------------------------------
- player addAction ["<t size='1'>[Restrain]</t>", "restrain.sqf", [], 1, false, true, 'true'];
- player addAction ["<t size='1'>[Unrestrain]</t>", "unrestrain.sqf", [], 1, false, true, 'true'];
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement