Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*_______________________________________
- based on: http://www.armaholic.com/page.php?id=30571
- paste into init.sqf:
- [] execVM "PW_holsterAction.sqf";
- __________________________________________*/
- waitUntil {!isNull (findDisplay 46)};
- (findDisplay 46) displayAddEventHandler ["KeyDown", {
- private ["_return"];
- _return = false;
- if ((_this select 1) in (actionKeys "User16")) then {
- if(alive player) then {
- if(currentWeapon player != "") then { // we have some weapon drawn
- player action ["SWITCHWEAPON", player, player, -1]; // holster the weapon
- } else {
- player action ["SWITCHWEAPON", player, player, 0]; // switch to primary
- };
- _return = true;
- };
- };
- _return;
- }];
Advertisement
Add Comment
Please, Sign In to add comment