From e6eb94197dbf64efd9e80f6255e85382cfbe6297 Mon Sep 17 00:00:00 2001 From: A Man Date: Wed, 18 Aug 2021 21:30:48 +0200 Subject: [PATCH] Add toggleable vehicle key changer by salival --- .../Configs/RscDisplay/vehicleKeyChanger.hpp | 315 ++++++++++++++++++ SQF/dayz_code/actions/vkc/vehicleInfo.sqf | 68 ++++ .../actions/vkc/vehicleKeyChanger.sqf | 175 ++++++++++ SQF/dayz_code/compile/fn_selfActions.sqf | 39 ++- SQF/dayz_code/config.cpp | 1 + SQF/dayz_code/configVariables.sqf | 16 +- SQF/dayz_code/init/compiles.sqf | 6 +- SQF/dayz_code/init/variables.sqf | 4 +- .../compile/server_publishVehicle3_vkc.sqf | 205 ++++++++++++ SQF/dayz_server/init/server_functions.sqf | 6 +- .../DZE_Server_Config/BattlEye/scripts.txt | 14 +- 11 files changed, 833 insertions(+), 16 deletions(-) create mode 100644 SQF/dayz_code/Configs/RscDisplay/vehicleKeyChanger.hpp create mode 100644 SQF/dayz_code/actions/vkc/vehicleInfo.sqf create mode 100644 SQF/dayz_code/actions/vkc/vehicleKeyChanger.sqf create mode 100644 SQF/dayz_server/compile/server_publishVehicle3_vkc.sqf diff --git a/SQF/dayz_code/Configs/RscDisplay/vehicleKeyChanger.hpp b/SQF/dayz_code/Configs/RscDisplay/vehicleKeyChanger.hpp new file mode 100644 index 000000000..96e4868d5 --- /dev/null +++ b/SQF/dayz_code/Configs/RscDisplay/vehicleKeyChanger.hpp @@ -0,0 +1,315 @@ +class vkc_RscText { + idc = -1; + x = 0; + y = 0; + h = 0.037; + w = 0.3; + type = 0; + style = 0; + shadow = 2; + colorShadow[] = {0, 0, 0, 0.5}; + font = "Zeppelin32"; + SizeEx = "(((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1)"; + text = ""; + colorText[] = {1, 1, 1, 1.0}; + colorBackground[] = {0, 0, 0, 0}; + linespacing = 1; + tooltipColorText[] = {1,1,1,1}; + tooltipColorBox[] = {1,1,1,1}; + tooltipColorShade[] = {0,0,0,0.65}; +}; + +class vkc_RscTitle : vkc_RscText { + idc = -1; + style = 0; + sizeEx = "(((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1)"; + colorText[] = {0.95, 0.95, 0.95, 1}; +}; + +class vkc_RscShortcutButton { + idc = -1; + style = 0; + default = 0; + shadow = 2; + w = 0.183825; + h = "((((safezoneW / safezoneH) min 1.2) / 1.2) / 20)"; + color[] = {1,1,1,1.0}; + colorFocused[] = {1,1,1,1.0}; + color2[] = {0.95,0.95,0.95,1}; + colorDisabled[] = {1,1,1,0.25}; + colorBackground[] = {"(profilenamespace getvariable ['GUI_BCG_RGB_R',0.69])","(profilenamespace getvariable ['GUI_BCG_RGB_G',0.75])","(profilenamespace getvariable ['GUI_BCG_RGB_B',0.5])",1}; + colorBackgroundFocused[] = {"(profilenamespace getvariable ['GUI_BCG_RGB_R',0.69])","(profilenamespace getvariable ['GUI_BCG_RGB_G',0.75])","(profilenamespace getvariable ['GUI_BCG_RGB_B',0.5])",1}; + colorBackground2[] = {1,1,1,1}; + animTextureDefault = "gza\scripts\gold\gui\normal_ca.paa"; + animTextureNormal = "gza\scripts\gold\gui\normal_ca.paa"; + animTextureDisabled = "gza\scripts\gold\gui\normal_ca.paa"; + animTextureOver = "gza\scripts\gold\gui\over_ca.paa"; + animTextureFocused = "gza\scripts\gold\gui\focus_ca.paa"; + animTexturePressed = "gza\scripts\gold\gui\down_ca.paa"; + periodFocus = 1.2; + periodOver = 0.8; + class HitZone { + left = 0.0; + top = 0.0; + right = 0.0; + bottom = 0.0; + }; + class ShortcutPos { + left = 0; + top = "(((((safezoneW / safezoneH) min 1.2) / 1.2) / 20) - (((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1)) / 2"; + w = "(((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1) * (3/4)"; + h = "(((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1)"; + }; + class TextPos { + left = "(((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1) * (3/4)"; + top = "(((((safezoneW / safezoneH) min 1.2) / 1.2) / 20) - (((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1)) / 2"; + right = 0.005; + bottom = 0.0; + }; + period = 0.4; + font = "Zeppelin32"; + size = "(((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1)"; + sizeEx = "(((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1)"; + text = ""; + action = ""; + class Attributes { + font = "Zeppelin32"; + color = "#E5E5E5"; + align = "left"; + shadow = 1; + }; + class AttributesImage { + font = "Zeppelin32"; + color = "#E5E5E5"; + align = "left"; + }; + soundPush[] = { "", 0, 1 }; + soundEnter[] ={ "", 0, 1 }; + soundClick[] ={ "", 0, 1 }; + soundEscape[] ={ "", 0, 1 }; + sound[] ={ "", 0, 1 }; +}; + +class vkc_RscButtonMenu : vkc_RscShortcutButton { + idc = -1; + type = 16; + style = "0x02 + 0xC0"; + default = 0; + shadow = 0; + x = 0; + y = 0; + w = 0.095589; + h = 0.039216; + animTextureNormal = "#(argb,8,8,3)color(1,1,1,1)"; + animTextureDisabled = "#(argb,8,8,3)color(1,1,1,1)"; + animTextureOver = "#(argb,8,8,3)color(1,1,1,1)"; + animTextureFocused = "#(argb,8,8,3)color(1,1,1,1)"; + animTexturePressed = "#(argb,8,8,3)color(1,1,1,1)"; + animTextureDefault = "#(argb,8,8,3)color(1,1,1,1)"; + colorBackground[] = {0,0,0,0.8}; + colorBackgroundFocused[] = {1,1,1,1}; + colorBackground2[] = {0.75,0.75,0.75,1}; + color[] = {1,1,1,1}; + colorFocused[] = {0,0,0,1}; + color2[] = {0,0,0,1}; + colorText[] = {1,1,1,1}; + colorDisabled[] = {1,1,1,0.25}; + period = 1.2; + periodFocus = 1.2; + periodOver = 1.2; + size = "(((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1)"; + sizeEx = "(((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1)"; + tooltipColorText[] = {1,1,1,1}; + tooltipColorBox[] = {1,1,1,1}; + tooltipColorShade[] = {0,0,0,0.65}; + class TextPos { + left = "0.25 * (((safezoneW / safezoneH) min 1.2) / 40)"; + top = "(((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) - (((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1)) / 2"; + right = 0.005; + bottom = 0.0; + }; + class Attributes { + font = "Zeppelin32"; + color = "#E5E5E5"; + align = "center"; + shadow = 0; + }; + class ShortcutPos { + left = "(6.25 * (((safezoneW / safezoneH) min 1.2) / 40)) - 0.0225 - 0.005"; + top = 0.005; + w = 0.0225; + h = 0.03; + }; + textureNoShortcut = ""; +}; + +class vkc_RscListBox { + style = 16; + idc = -1; + type = 5; + w = 0.275; + h = 0.04; + font = "Zeppelin32"; + colorSelect[] = {0.11,0.686,0.831,1}; + colorText[] = {1, 1, 1, 1}; + colorBackground[] = {0.28,0.28,0.28,0.28}; + colorSelect2[] = {1, 1, 1, 1}; + colorSelectBackground[] = {0.95, 0.95, 0.95, 0.5}; + colorSelectBackground2[] = {1, 1, 1, 0.5}; + colorScrollbar[] = {0.2, 0.2, 0.2, 1}; + arrowFull = "\ca\ui\data\igui_arrow_top_active_ca.paa"; + arrowEmpty = "\ca\ui\data\igui_arrow_top_ca.paa"; + wholeHeight = 0.45; + rowHeight = 0.04; + color[] = {0.7, 0.7, 0.7, 1}; + colorActive[] = {0,0,0,1}; + colorDisabled[] = {0,0,0,0.3}; + sizeEx = 0.023; + maxHistoryDelay = 1; + autoScrollSpeed = -1; + autoScrollDelay = 5; + autoScrollRewind = 0; + tooltipColorText[] = {1,1,1,1}; + tooltipColorBox[] = {1,1,1,1}; + tooltipColorShade[] = {0,0,0,0.65}; + class ScrollBar { + color[] = {1, 1, 1, 0.6}; + colorActive[] = {1, 1, 1, 1}; + colorDisabled[] = {1, 1, 1, 0.3}; + thumb = "\ca\ui\data\igui_scrollbar_thumb_ca.paa"; + arrowFull = "\ca\ui\data\igui_arrow_top_active_ca.paa"; + arrowEmpty = "\ca\ui\data\igui_arrow_top_ca.paa"; + border = "\ca\ui\data\igui_border_scroll_ca.paa"; + }; + soundPush[] = { "", 0, 1 }; + soundEnter[] ={ "", 0, 1 }; + soundClick[] ={ "", 0, 1 }; + soundEscape[] ={ "", 0, 1 }; + sound[] ={ "", 0, 1 }; + soundSelect[] = { "", 0, 1 }; +}; + +class vkc_RscStructuredText { + type = 13; + style = 0; + x = 0; + y = 0; + h = 0.035; + w = 0.1; + text = ""; + size = "(((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) * 1)"; + colorText[] = {1, 1, 1, 1.0}; + shadow = 1; + class Attributes { + font = "Zeppelin32"; + color = "#ffffff"; + align = "left"; + shadow = 1; + }; +}; + +class vkc { + idd = 4800; + name="vkc"; + onload = "player setVariable['isBusy',true,true];"; + onUnload = "player setVariable['isBusy',false,true];"; + movingEnabled = 0; + enableSimulation = 1; + + class controlsBackground { + class vkc_RscTitleBackground : vkc_RscText { + colorBackground[] = {"(profilenamespace getvariable ['GUI_BCG_RGB_R',0.3843])", "(profilenamespace getvariable ['GUI_BCG_RGB_G',0.7019])", "(profilenamespace getvariable ['GUI_BCG_RGB_B',0.8862])", "(profilenamespace getvariable ['GUI_BCG_RGB_A',0.7])"}; + idc = -1; + x = 0.1; + y = 0.2; + w = 0.8; + h = (1 / 25); + }; + + class MainBackground : vkc_RscText { + colorBackground[] = {0,0,0,0.7}; + idc = -1; + x = 0.1; + y = 0.2 + (11 / 250); + w = 0.8; + h = 0.7 - (22 / 250); + }; + + class Title : vkc_RscTitle { + idc = 4801; + text = $STR_CL_VKC_TITLE; + x = 0.1; + y = 0.2; + w = 0.8; + h = (1 / 25); + }; + + class VehicleInfoHeader : vkc_RscText { + idc = 4830; + text = $STR_CL_VKC_INFO; + colorBackground[] = {"(profilenamespace getvariable ['GUI_BCG_RGB_R',0.3843])", "(profilenamespace getvariable ['GUI_BCG_RGB_G',0.7019])", "(profilenamespace getvariable ['GUI_BCG_RGB_B',0.8862])", "(profilenamespace getvariable ['GUI_BCG_RGB_A',0.7])"}; + x = 0.47; y = 0.26; + w = 0.42; + h = (1 / 25); + }; + + class CloseBtn : vkc_RscButtonMenu { + idc = -1; + text = $STR_UI_CLOSE; + onButtonClick = "closeDialog 2;"; + x = -0.06 + (6.25 / 40) + (1 / 250 / (safezoneW / safezoneH)); + y = 0.9 - (1 / 25); + w = (6.25 / 40); + h = (1 / 25); + }; + }; + + class controls { + class VehicleList : vkc_RscListBox { + idc = 4802; + text = ""; + sizeEx = 0.04; + colorBackground[] = {0.1,0.1,0.1,0.9}; + onLBSelChanged = "vkc_charID = (vkc_keyList select 0) select (lbCurSel 4802);vkc_keyName = (vkc_keyList select 1) select (lbCurSel 4802);"; + x = 0.11; y = 0.302; + w = 0.35; h = 0.49; + }; + + class VehicleTitleBox : vkc_RscText { + idc = 4804; + text = $STR_CL_VKC_KEYS; + colorBackground[] = {"(profilenamespace getvariable ['GUI_BCG_RGB_R',0.3843])", "(profilenamespace getvariable ['GUI_BCG_RGB_G',0.7019])", "(profilenamespace getvariable ['GUI_BCG_RGB_B',0.8862])", "(profilenamespace getvariable ['GUI_BCG_RGB_A',0.7])"}; + x = 0.11; y = 0.26; + w = 0.35; + h = (1 / 25); + }; + + class claimVehicle : vkc_RscButtonMenu { + idc = 4850; + text = $STR_CL_VKC_CLAIM; + onButtonClick = "vkc_isOk = true;closeDialog 0;"; + x = 0.1 + (6.25 / 40) + (1 / 250 / (safezoneW / safezoneH)); + y = 0.9 - (1 / 25); + w = (6.25 / 20); + h = (1 / 25); + }; + + class changeKey : vkc_RscButtonMenu { + idc = 4851; + text = $STR_CL_VKC_CHANGE; + onButtonClick = "vkc_isOk = true;closeDialog 0;"; + x = 0.1 + (6.25 / 40) + (1 / 250 / (safezoneW / safezoneH)); + y = 0.9 - (1 / 25); + w = (6.25 / 20); + h = (1 / 25); + }; + + class vehicleInfomationList : vkc_RscStructuredText { + idc = 4803; + text = ""; + sizeEx = 0.035; + x = 0.47; y = 0.3; + w = 0.41; h = 0.5; + }; + }; +}; diff --git a/SQF/dayz_code/actions/vkc/vehicleInfo.sqf b/SQF/dayz_code/actions/vkc/vehicleInfo.sqf new file mode 100644 index 000000000..e430206b3 --- /dev/null +++ b/SQF/dayz_code/actions/vkc/vehicleInfo.sqf @@ -0,0 +1,68 @@ +private ["_backPackCount","_backPackCount_raw","_backPackSlots","_formattedText","_gearCount","_magazineCount","_magazineCount_raw","_magazineSlots","_name","_picture","_price","_text","_typeOf","_weaponSlots","_weaponsCount","_weaponsCount_raw"]; + +_gearCount = { + private ["_counter"]; + _counter = 0; + {_counter = _counter + _x;} count _this; + _counter +}; + +if (vkc_action == "claim") then { + ctrlShow[4850,true]; + _text = localize "STR_CL_VKC_CLAIM"; + _price = vkc_claimPrice; +} else { + ctrlShow[4851,true]; + _text = localize "STR_CL_VKC_CHANGE"; + _price = vkc_changePrice; +}; + +_typeOf = typeOf vkc_cursorTarget; +_weaponsCount_raw = getWeaponCargo vkc_cursorTarget; +_magazineCount_raw = getMagazineCargo vkc_cursorTarget; +_backPackCount_raw = getBackpackCargo vkc_cursorTarget; + +_weaponSlots = getNumber(configFile >> "CfgVehicles" >> _typeOf >> "transportMaxWeapons"); +_magazineSlots = getNumber(configFile >> "CfgVehicles" >> _typeOf >> "transportMaxMagazines"); +_backPackSlots = getNumber(configFile >> "CfgVehicles" >> _typeOf >> "transportmaxbackpacks"); +_name = getText(configFile >> "CfgVehicles" >> _typeOf >> "displayName"); +_picture = getText(configFile >> 'CfgVehicles' >> _typeOf >> 'picture'); + +_weaponsCount = (_weaponsCount_raw select 1) call _gearCount; +_magazineCount = (_magazineCount_raw select 1) call _gearCount; +_backPackCount = (_backPackCount_raw select 1) call _gearCount; + +if (!isNil "sk_dualCurrency") then {if (z_singleCurrency) then {_price = _price * 10};}; + +_price = if (z_singleCurrency) then { + format ["%1 %2",[_price] call BIS_fnc_numberText,currencyName] +} else { + [_price,true] call z_calcCurrency +}; +_formattedText = format [ + "
" + + "%2: %3
" + + "%4: %5
" + + "%6: %13/%10 %14/%11 %15/%12
" + + "Price to %16: %17
", + _picture, + localize "STR_EPOCH_NAME", + _name, + localize "STR_EPOCH_CLASS", + _typeOf, + localize "STR_EPOCH_CARGO_SPACE", + "\z\addons\dayz_code\gui\gear\gear_ui_slots_weapons_white.paa", + "\z\addons\dayz_code\gui\gear\gear_ui_slots_items_white.paa", + "\z\addons\dayz_code\gui\gear\gear_ui_slots_backPacks_white.paa", + _weaponSlots, + _magazineSlots, + _backPackSlots, + _weaponsCount, + _magazineCount, + _backPackCount, + toLower (_text), + _price +]; + +((findDisplay 4800) displayCtrl 4803) ctrlSetStructuredText parseText _formattedText; +ctrlShow [4803,true]; diff --git a/SQF/dayz_code/actions/vkc/vehicleKeyChanger.sqf b/SQF/dayz_code/actions/vkc/vehicleKeyChanger.sqf new file mode 100644 index 000000000..dd003f4c0 --- /dev/null +++ b/SQF/dayz_code/actions/vkc/vehicleKeyChanger.sqf @@ -0,0 +1,175 @@ +/* + Vehicle Key Changer by salival (https://github.com/oiad) + + This version adds support for both single currency and gems (from the epoch 1.0.6 update) as well as the original epoch briefcase currency system. + Instead of pricing things like the original way, prices are now done on a "worth" similar to how coins are done. The price value of items are below. + If you are using coins, I would recommend using the _currencyModifier variable since coins typically are 10x the value of briefcase based currency (1 brief == 100,000 coins) + + 1 silver = 1 worth + 1 10oz silver = 10 worth + 1 gold = 100 worth + 1 10oz gold = 1,000 worth + 1 briefcase = 10,000 worth + + Please see dayz_code\configVariables.sqf for the value of gems (DZE_GemWorthArray) and their relevant worth if they are enabled. +*/ + +if (dayz_actionInProgress) exitWith {localize "str_player_actionslimit" call dayz_rollingMessages;}; +dayz_actionInProgress = true; + +disableSerialization; +private ["_amount","_characterID","_control","_currencyModifier","_enoughMoney","_exit","_foundPos","_index","_itemText","_message","_moneyInfo","_name","_playerNear","_position","_success","_typeOf","_vehicleID","_vehicleUID","_wealth"]; + +vkc_cursorTarget = (_this select 3) select 0; +_characterID = (_this select 3) select 1; +vkc_action = (_this select 3) select 2; + +vkc_isOk = false; + +player removeAction s_player_claimVehicle; +s_player_claimVehicle = 1; +player removeAction s_player_copyToKey; +s_player_copyToKey = 1; + +_exit = { + vkc_action = nil; + vkc_keyList = nil; + vkc_keyName = nil; + vkc_charID = nil; + vkc_isOk = nil; + vkc_cursorTarget = nil; + s_player_copyToKey = -1; + s_player_claimVehicle = -1; + dayz_actionInProgress = false; +}; + +if (isNull vkc_cursorTarget) exitWith {call _exit; systemChat localize "str_cursorTargetNotFound";}; + +_playerNear = {isPlayer _x} count (([vkc_cursorTarget] call FNC_GetPos) nearEntities ["CAManBase", 10]) > 1; +if (_playerNear) exitWith {call _exit; localize "str_pickup_limit_5" call dayz_rollingMessages;}; + +if !(vkc_cursorTarget isKindOf "Air" || {vkc_cursorTarget isKindOf "LandVehicle"} || {vkc_cursorTarget isKindOf "Ship"}) exitWith {call _exit; localize "STR_CL_VKC_FAIL_CURSOR" call dayz_rollingMessages;}; + +if (isNull DZE_myVehicle || {!(alive DZE_myVehicle)} || {!(local DZE_myVehicle)}) exitWith {call _exit; localize "str_epoch_player_245" call dayz_rollingMessages;}; + +_vehicleID = vkc_cursorTarget getVariable ["ObjectID","0"]; +_vehicleUID = vkc_cursorTarget getVariable ["ObjectUID","0"]; + +_typeOf = typeOf vkc_cursorTarget; +_name = getText(configFile >> "cfgVehicles" >> _typeOf >> "displayName"); + +if ((_vehicleID == "0" && {_vehicleUID == "0"}) || {_vehicleID == "1" || _vehicleUID == "1"}) exitWith {call _exit; format[localize "STR_CL_VKC_FAIL_SUPPORT",_name] call dayz_rollingMessages;}; + +if (_vehicleUID == "0") then { + _vehicleUID = ""; + { + _x = _x * 10; + if (_x < 0) then {_x = _x * -10}; + _vehicleUID = _vehicleUID + str(round(_x)); + } forEach getPosATL vkc_cursorTarget; + _vehicleUID = _vehicleUID + str(round((getDir vkc_cursorTarget) + time)); + vkc_cursorTarget setVariable["ObjectUID",_vehicleUID,true]; +}; + +vkc_keyList = call epoch_tempKeys; + +if (vkc_action == "change") then { + _amount = vkc_changePrice; + _message = [localize "STR_CL_VKC_CHANGE_MESSAGE_1",localize "STR_CL_VKC_CHANGE_MESSAGE_2",localize "STR_CL_VKC_CHANGE_MESSAGE_3"]; + _foundPos = (vkc_keyList select 0) find _characterID; + if (_foundPos >= 0) then { + vkc_keyList set [0,(vkc_keyList select 0) - [(vkc_keyList select 0) select _foundPos]]; + vkc_keyList set [1,(vkc_keyList select 1) - [(vkc_keyList select 1) select _foundPos]]; + vkc_keyList set [2,(vkc_keyList select 2) - [(vkc_keyList select 2) select _foundPos]]; + } else { + vkc_keyList = [[],[]]; + }; +} else { + _amount = vkc_claimPrice; + _message = [localize "STR_CL_VKC_CLAIM_MESSAGE_1",localize "STR_CL_VKC_CLAIM_MESSAGE_2",localize "STR_CL_VKC_CLAIM_MESSAGE_3"]; +}; + +if (count (vkc_keyList select 0) == 0) exitWith {systemChat localize "STR_CL_VKC_FAIL_KEYS"; call _exit;}; + +if (!isNil "sk_dualCurrency") then {if (z_singleCurrency) then {_amount = _amount * 10};}; + +_itemText = if (Z_SingleCurrency) then {format ["%1 %2",[_amount] call BIS_fnc_numberText,CurrencyName]} else {[_amount,true] call z_calcCurrency}; + +createDialog "vkc"; +{ctrlShow [_x,false]} count [4803,4850,4851]; + +call vkc_vehicleInfo; + +_control = ((findDisplay 4800) displayCtrl 4802); +lbClear _control; + +{ + _index = _control lbAdd ((vkc_keyList select 1) select _forEachIndex); + _control lbSetPicture [_index,getText(configFile >> "CfgWeapons" >> ((vkc_keyList select 2) select _index) >> "picture")]; +} forEach (vkc_keyList select 0); + +_control lbSetCurSel 0; + +waitUntil {!dialog}; + +if (!vkc_isOk) exitWith {call _exit;}; + +if (isNull DZE_myVehicle || {!(alive DZE_myVehicle)} || {!(local DZE_myVehicle)}) exitWith {call _exit; localize "str_epoch_player_245" call dayz_rollingMessages;}; + +_enoughMoney = false; +_moneyInfo = [false,[],[],[],0]; + +if (Z_SingleCurrency) then { + _wealth = player getVariable [(["cashMoney","globalMoney"] select Z_persistentMoney),0]; + _enoughMoney = (_wealth >= _amount); +} else { + Z_Selling = false; + if (Z_AllowTakingMoneyFromVehicle) then {false call Z_checkCloseVehicle}; + _moneyInfo = _amount call Z_canAfford; + _enoughMoney = _moneyInfo select 0; +}; + +_success = if (Z_SingleCurrency) then {true} else {[player,_amount,_moneyInfo,true,0] call Z_payDefault}; + +if (!_success && {_enoughMoney}) exitWith {call _exit;systemChat localize "STR_EPOCH_TRADE_GEAR_AND_BAG_FULL"}; + +if (_enoughMoney) then { + _success = if (Z_SingleCurrency) then {_amount <= _wealth} else {[player,_amount,_moneyInfo,false,0] call Z_payDefault}; + if (_success) then { + if (Z_SingleCurrency) then {player setVariable [(["cashMoney","globalMoney"] select Z_persistentMoney),(_wealth - _amount),true];}; + + vkc_cursorTarget setVehicleLock "LOCKED"; + player playActionNow "Medic"; + + _position = [vkc_cursorTarget] call FNC_GetPos; + + [_typeOf,objNull] call fn_waitForObject; + dze_waiting = nil; + + PVDZE_veh_Upgrade = [vkc_cursorTarget,[getDir vkc_cursorTarget,_position],_typeOf,vkc_charID,player,dayz_authKey,if (vkc_action == "change") then {"changed the key for"} else {"claimed"}]; + publicVariableServer "PVDZE_veh_Upgrade"; + + localize "STR_CL_VKC_WAIT" call dayz_rollingMessages; + + waitUntil {!isNil "dze_waiting"}; + + if (dze_waiting == "fail") then { + systemChat format[localize "STR_CL_VKC_FAIL_UPGRADE",_name]; + if (z_singleCurrency) then { + player setVariable [(["cashMoney","globalMoney"] select Z_persistentMoney),_wealth,true]; + } else { + Z_Selling = true; + _success = [_amount,0,false,0,[],[],false] call Z_returnChange; + }; + } else { + {player reveal _x;} count (player nearEntities [["LandVehicle"],10]); + [format[_message select 0,_name,vkc_keyName],1] call dayz_rollingMessages; + }; + } else { + systemChat localize "STR_EPOCH_TRADE_DEBUG"; + }; +} else { + systemChat format[localize "STR_CL_VKC_FAIL_MONEY",_itemText,_message select 1,_name]; +}; + +call _exit; diff --git a/SQF/dayz_code/compile/fn_selfActions.sqf b/SQF/dayz_code/compile/fn_selfActions.sqf index 457877bc4..6c15df26c 100644 --- a/SQF/dayz_code/compile/fn_selfActions.sqf +++ b/SQF/dayz_code/compile/fn_selfActions.sqf @@ -234,6 +234,7 @@ if (!isNull _cursorTarget && {!_inVehicle && !_isPZombie && _canDo && player dis local _weaponsPlayer = weapons player; local _hasCrowbar = "ItemCrowbar" in _itemsPlayer || "MeleeCrowbar" in _weaponsPlayer || dayz_onBack == "MeleeCrowbar"; local _hasToolbox = "ItemToolbox" in _itemsPlayer; + local _hasKeymakerskit = "ItemKeyKit" in _itemsPlayer; local _isAlive = alive _cursorTarget; local _text = getText (configFile >> "CfgVehicles" >> _typeOfCursorTarget >> "displayName"); local _isPlant = _typeOfCursorTarget in Dayz_plants; @@ -568,11 +569,12 @@ if (!isNull _cursorTarget && {!_inVehicle && !_isPZombie && _canDo && player dis // Allow Owner to lock and unlock vehicle if (_player_lockUnlock_crtl) then { + local _totalKeys = call epoch_tempKeys; + local _temp_keys = _totalKeys select 0; + local _temp_keys_names = _totalKeys select 1; + local _hasKey = _characterID in _temp_keys; + if (s_player_lockUnlock_crtl < 0) then { - local _totalKeys = call epoch_tempKeys; - local _temp_keys = _totalKeys select 0; - local _temp_keys_names = _totalKeys select 1; - local _hasKey = _characterID in _temp_keys; local _oldOwner = (_characterID == _uid); local _unlock = []; @@ -598,9 +600,18 @@ if (!isNull _cursorTarget && {!_inVehicle && !_isPZombie && _canDo && player dis }; }; }; + if (DZE_VehicleKey_Changer) then { + if (s_player_copyToKey < 0) then { + if ((_hasKeymakerskit && _hasKey && !_isLocked && {(count _temp_keys) > 1}) || {_cursorTarget getVariable ["hotwired",false]}) then { + s_player_copyToKey = player addAction [format["%1",localize "STR_CL_VKC_CHANGE_ACTION"],"\z\addons\dayz_code\actions\vkc\vehicleKeyChanger.sqf",[_cursorTarget,_characterID,if (_cursorTarget getVariable ["hotwired",false]) then {"claim"} else {"change"}],5,false,true]; + }; + }; + }; } else { {player removeAction _x} count s_player_lockunlock;s_player_lockunlock = []; s_player_lockUnlock_crtl = -1; + player removeAction s_player_copyToKey; + s_player_copyToKey = -1; }; if (DZE_Hide_Body && {_isMan && !_isAlive}) then { @@ -809,6 +820,20 @@ if (!isNull _cursorTarget && {!_inVehicle && !_isPZombie && _canDo && player dis player removeAction s_player_fillgen; s_player_fillgen = -1; }; + + if (DZE_VehicleKey_Changer) then { + if (_hasKeymakerskit && _isVehicle && !_isMan && _isAlive && {_characterID == "0"}) then { + if (s_player_claimVehicle < 0) then { + _totalKeys = call epoch_tempKeys; + if (count (_totalKeys select 0) > 0) then { + s_player_claimVehicle = player addAction [format["%1",format[localize "STR_CL_VKC_CLAIM_ACTION",_text]],"\z\addons\dayz_code\actions\vkc\vehicleKeyChanger.sqf",[_cursorTarget,_characterID,"claim"],5,false,true]; + }; + }; + } else { + player removeAction s_player_claimVehicle; + s_player_claimVehicle = -1; + }; + }; if (!_isAlive && _isMan && !_isZombie && {!(_cursorTarget isKindOf "Animal")}) then { if (DZE_Take_Clothes) then { @@ -1123,7 +1148,11 @@ if (!isNull _cursorTarget && {!_inVehicle && !_isPZombie && _canDo && player dis player removeAction s_player_bury_human; s_player_bury_human = -1; player removeAction s_player_butcher_human; - s_player_butcher_human = -1; + s_player_butcher_human = -1; + player removeAction s_player_copyToKey; + s_player_copyToKey = -1; + player removeAction s_player_claimVehicle; + s_player_claimVehicle = -1; }; //Dog actions on player self diff --git a/SQF/dayz_code/config.cpp b/SQF/dayz_code/config.cpp index ad7d12120..b7ce25c89 100644 --- a/SQF/dayz_code/config.cpp +++ b/SQF/dayz_code/config.cpp @@ -130,6 +130,7 @@ class DefaultEventhandlers { #include "Configs\RscDisplay\doorManagement\doorAccess.hpp" #include "Configs\RscDisplay\zscDialogs.hpp" #include "Configs\RscDisplay\remoteVehicle.hpp" +#include "Configs\RscDisplay\vehicleKeyChanger.hpp" //#include "Configs\RscDisplay\tradermenu.hpp" class CfgTasks diff --git a/SQF/dayz_code/configVariables.sqf b/SQF/dayz_code/configVariables.sqf index 0555d3115..c4f9b10a9 100644 --- a/SQF/dayz_code/configVariables.sqf +++ b/SQF/dayz_code/configVariables.sqf @@ -36,6 +36,9 @@ if (Z_SingleCurrency) then { Z_VehicleDistance = 40; // Max distance a vehicle can be sold or accessed from at a trader. +// Vehicle Key Changer +DZE_VehicleKey_Changer = true; // Enable Vehicle Key Changer. Create or change the key for a vehicle. + // Plot Management and Plot for Life DZE_permanentPlot = true; // Plot ownership saves after death. Enables Plot for Life by @RimBlock and Plot Management by @DevZupa. DZE_isRemovable = ["Plastic_Pole_EP1_DZ"]; //Items that can be removed with a crowbar with no ownership or access required. To forbid base take overs remove plot pole from this list and add it to DZE_restrictRemoval. It is not necessary to add wrecks or items that inherit from 'BuiltItems' to this list. @@ -100,6 +103,11 @@ if (isServer) then { // Safe Zone Relocating DZE_SafeZone_Relocate = false; //Enables relocating of vehicles left in Safe Zones over a server restart. + + if (DZE_VehicleKey_Changer) then { + vkc_clearAmmo = true; // Clear the ammo of vehicles after they have been rekeyed/claimed? (stops users getting a free rearm) + vkc_disableThermal = [""]; // Array of vehicle config classes as well as vehicle classnames to disable thermal on when being spawned. i.e: ["All","Land","Air","Ship","StaticWeapon","AH1Z","MTVR"]; + }; }; // Client @@ -240,6 +248,7 @@ if (!isDedicated) then { dayz_matchboxCount = false; // Enable match stick count. After five uses matches run out and must be replaced. dayz_waterBottleBreaking = false; // Water bottles have a chance to break when boiling and require duct tape to fix + // Bury and Butcher Bodies if (DZE_Bury_Body) then { DZE_Bury_Body_Value = 30;// Amount of humanity to gain for burying a body. }; @@ -290,6 +299,11 @@ if (!isDedicated) then { ]; }; + if (DZE_VehicleKey_Changer) then { + vkc_claimPrice = 1000; // Amount in worth for claiming a vehicle. See the top of this script for an explanation. + vkc_changePrice = 5000; // Amount in worth for changing the key for a vehicle. See the top of this script for an explanation. + }; + // Bloodsuckers DZE_Bloodsuckers = false; // Enable bloodsucker spawning. @@ -439,4 +453,4 @@ if (!isDedicated) then { Variables that are map specific or frequently changed should be included in init.sqf by default with a corresponding if(isNil)then{}; in variables.sqf. -*/ +*/ \ No newline at end of file diff --git a/SQF/dayz_code/init/compiles.sqf b/SQF/dayz_code/init/compiles.sqf index f3a1078a0..0b59c812c 100644 --- a/SQF/dayz_code/init/compiles.sqf +++ b/SQF/dayz_code/init/compiles.sqf @@ -208,6 +208,10 @@ if (!isDedicated) then { locateVehicle = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\locateVehicle.sqf"; }; + if (DZE_VehicleKey_Changer) then { + vkc_vehicleInfo = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\vkc\vehicleInfo.sqf"; + }; + if (DZE_Service_Points) then { execVM "\z\addons\dayz_code\actions\servicePoints\init.sqf"; }; @@ -217,7 +221,7 @@ if (!isDedicated) then { player_mutantAttack = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\player_mutantAttack.sqf"; mutant_generate = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\mutant_generate.sqf"; mutant_findTarget = compile preprocessFileLineNumbers "\z\addons\dayz_code\compile\mutant_findTarget.sqf"; - }; + }; // Weather if (DZE_Weather in [3,4]) then { diff --git a/SQF/dayz_code/init/variables.sqf b/SQF/dayz_code/init/variables.sqf index 3f2605696..4d572ea42 100644 --- a/SQF/dayz_code/init/variables.sqf +++ b/SQF/dayz_code/init/variables.sqf @@ -211,7 +211,9 @@ if (!isDedicated) then { s_player_gdoor_opener = []; s_player_gdoor_opener_ctrl = -1; s_player_bury_human = -1; - s_player_butcher_human = -1; + s_player_butcher_human = -1; + s_player_copyToKey = -1; + s_player_claimVehicle = -1; }; call dayz_resetSelfActions; diff --git a/SQF/dayz_server/compile/server_publishVehicle3_vkc.sqf b/SQF/dayz_server/compile/server_publishVehicle3_vkc.sqf new file mode 100644 index 000000000..0c0070fd1 --- /dev/null +++ b/SQF/dayz_server/compile/server_publishVehicle3_vkc.sqf @@ -0,0 +1,205 @@ +private ["_coins","_activatingPlayer","_object","_worldspace","_location","_dir","_class","_uid","_key","_keySelected" +,"_characterID","_result","_outcome","_oid","_objectID","_objectUID","_newobject","_weapons","_magazines","_backpacks" +,"_clientKey","_exitReason","_playerUID","_isAir","_fuel","_selection","_dam","_hitpoints","_newHitpoints","_damage" +,"_hit","_inv","_action","_clearTurrets","_message"]; +#include "\z\addons\dayz_server\compile\server_toggle_debug.hpp" + +if (count _this < 6) exitWith { + diag_log "Server_PublishVehicle3 error: Wrong parameter format"; + dze_waiting = "fail"; + (owner (_this select 4)) publicVariableClient "dze_waiting"; +}; + +_object = _this select 0; +_worldspace = _this select 1; +_class = _this select 2; +_keySelected = _this select 3; +_activatingPlayer = _this select 4; +_clientKey = _this select 5; +_action = if (count _this > 6) then {_this select 6} else {""}; +_playerUID = getPlayerUID _activatingPlayer; +_characterID = _keySelected; + +_exitReason = [_this,"PublishVehicle3",(_worldspace select 1),_clientKey,_playerUID,_activatingPlayer] call server_verifySender; +if (_exitReason != "") exitWith { + diag_log _exitReason; + dze_waiting = "fail"; + (owner _activatingPlayer) publicVariableClient "dze_waiting"; +}; + +if (!(isClass(configFile >> "CfgVehicles" >> _class)) || isNull _object) exitWith { + diag_log ("HIVE-PublishVehicle3 Error: Vehicle does not exist: "+ str(_class)); + dze_waiting = "fail"; + (owner _activatingPlayer) publicVariableClient "dze_waiting"; +}; + +_objectID = _object getVariable ["ObjectID","0"]; +_objectUID = _object getVariable ["ObjectUID","0"]; +_location = [_object] call fnc_getPos; +_fuel = fuel _object; +_hitpoints = _object call vehicle_getHitpoints; +_newHitpoints = []; +_damage = damage _object; + +// add items from previous vehicle here +_weapons = getWeaponCargo _object; +_magazines = getMagazineCargo _object; +_backpacks = getBackpackCargo _object; +_inv = [_weapons,_magazines,_backpacks]; + +if (Z_SingleCurrency && {ZSC_VehicleMoneyStorage}) then { + _coins = _object getVariable ["cashMoney",0]; +}; + +{ + _hit = [_object,_x] call object_getHit; + if ((_hit select 0) > 0) then { + _newHitpoints set [count _newHitpoints,[(_hit select 1),(_hit select 0)]]; + } else { + _newHitpoints set [count _newHitpoints,[(_hit select 1),0]]; + }; +} count _hitpoints; + +#ifdef OBJECT_DEBUG +diag_log ("PUBLISH: Attempt " + str(_object)); +#endif + +_dir = _worldspace select 0; +_uid = _worldspace call dayz_objectUID2; + +_key = format["CHILD:308:%1:%2:%3:%4:%5:%6:%7:%8:%9:",dayZ_instance, _class, _damage , _characterID, _worldspace, _inv, _newHitpoints, _fuel,_uid]; +#ifdef OBJECT_DEBUG +diag_log ("HIVE: WRITE: "+ str(_key)); +#endif + +_key call server_hiveWrite; + +// GET DB ID +_key = format["CHILD:388:%1:",_uid]; +#ifdef OBJECT_DEBUG +diag_log ("HIVE: WRITE: "+ str(_key)); +#endif +_result = _key call server_hiveReadWrite; +_outcome = _result select 0; + +if (_outcome != "PASS") then { + diag_log("HIVE-pv3: failed to get id for : " + str(_uid)); + _key = format["CHILD:310:%1:",_uid]; + _key call server_hiveWrite; + dze_waiting = "fail"; + (owner _activatingPlayer) publicVariableClient "dze_waiting"; +} else { + _oid = _result select 1; + #ifdef OBJECT_DEBUG + diag_log("CUSTOM: Selected " + str(_oid)); + #endif + + _colour = _object getVariable ["Colour","0"]; + _colour2 = _object getVariable ["Colour2","0"]; + + deleteVehicle _object; + [_objectID,_objectUID,_object] call server_deleteObjDirect; + + uiSleep 3; + + _newobject = _class createVehicle [0,0,0]; + + // switch var to new vehicle at this point. + _object = _newobject; + + _object setVariable ["ObjectID", _oid, true]; + _object setVariable ["lastUpdate",diag_tickTime]; + _object setVariable ["CharacterID", _characterID, true]; + + if (Z_SingleCurrency && {ZSC_VehicleMoneyStorage && {_coins > 0}}) then { + _object setVariable ["cashMoney",_coins,true]; + }; + + dayz_serverObjectMonitor set [count dayz_serverObjectMonitor,_object]; + + clearWeaponCargoGlobal _object; + clearMagazineCargoGlobal _object; + clearBackpackCargoGlobal _object; + + _object setDir _dir; + _object setPosATL _location; + _object setVectorUp surfaceNormal _location; + _object setDamage _damage; + + if (_colour != "0") then { + _object setVariable ["Colour",_colour,true]; + _clrinit = format ["#(argb,8,8,3)color(%1)",_colour]; + _object setVehicleInit "this setObjectTexture [0,"+str _clrinit+"];"; + }; + + if (_colour2 != "0") then { + _object setVariable ["Colour2",_colour2,true]; + _clrinit2 = format ["#(argb,8,8,3)color(%1)",_colour2]; + _object setVehicleInit "this setObjectTexture [1,"+str _clrinit2+"];"; + }; + + processInitCommands; + [_weapons,_magazines,_backpacks,_object] call fn_addCargo; + + _clearTurrets = { + //By denvdmj (probably, I found it on the biki) + private ["_weaponArray","_findRecurse","_class","_obj","_turret","_mags"]; + _obj = _this; + + _weaponArray = []; + _weaponArray set [count _weaponArray,[-1]]; + + _findRecurse = { + private ["_root", "_class", "_path", "_currentPath", "_thisThis"]; + _root = (_this select 0); + _path = +(_this select 1); + _thisThis = _this select 2; + for "_i" from 0 to count _root -1 do { + _class = _root select _i; + if (isClass _class) then { + _currentPath = _path + [_i]; + {_weaponArray set [count _weaponArray, _currentPath];} count getArray (_class >> "weapons"); + _class = _class >> "turrets"; + if (isClass _class) then {[_class, _currentPath, _thisThis] call _findRecurse;}; + }; + }; + }; + + [configFile >> "CfgVehicles" >> typeOf (_obj) >> "turrets", [], _this] call _findRecurse; + + { + _turret = _x; + _mags = _obj magazinesTurret _turret; + {_obj removeMagazinesTurret[_x,_turret];} count _mags; + } forEach _weaponArray; + }; + + _isAir = _object isKindOf "Air"; + { + _selection = _x select 0; + _dam = [_x select 1,(_x select 1) min 0.8] select (!_isAir && {_selection in dayZ_explosiveParts}); + _object setHit [_selection,_dam]; + } count _newHitpoints; + + _object setFuel _fuel; + + [_object,"all",true] call server_updateObject; + + _object call fnc_veh_ResetEH; + // for non JIP users this should make sure everyone has eventhandlers for vehicles. + PVDZE_veh_Init = _object; + publicVariable "PVDZE_veh_Init"; + + {if (_object isKindOf _x) exitWith {_object disableTIEquipment true;}} count vkc_disableThermal; + if (vkc_clearAmmo) then {_object call _clearTurrets;}; + + dze_waiting = "success"; + (owner _activatingPlayer) publicVariableClient "dze_waiting"; + + if (_action == "") then { + _message = format["PUBLISH: %1(%2) upgraded %3 with UID %4 @%5",(_activatingPlayer call fa_plr2str),_playerUID,_class,_uid,(_location call fa_coor2str)]; + } else { + _message = format["PUBLISH: %1(%2) %6 %3 with UID %4 @%5",(_activatingPlayer call fa_plr2str),_playerUID,_class,_uid,(_location call fa_coor2str),_action]; + }; + diag_log _message; +}; diff --git a/SQF/dayz_server/init/server_functions.sqf b/SQF/dayz_server/init/server_functions.sqf index 741f7d9ed..9835508dc 100644 --- a/SQF/dayz_server/init/server_functions.sqf +++ b/SQF/dayz_server/init/server_functions.sqf @@ -39,7 +39,11 @@ server_verifySender = compile preprocessFileLineNumbers "\z\addons\dayz_server\c server_swapObject = compile preprocessFileLineNumbers "\z\addons\dayz_server\compile\server_swapObject.sqf"; //Used to downgrade and upgrade Epoch buildables server_publishVeh = compile preprocessFileLineNumbers "\z\addons\dayz_server\compile\server_publishVehicle.sqf"; //Used to spawn random vehicles by server server_publishVeh2 = compile preprocessFileLineNumbers "\z\addons\dayz_server\compile\server_publishVehicle2.sqf"; //Used to purchase vehicles at traders -server_publishVeh3 = compile preprocessFileLineNumbers "\z\addons\dayz_server\compile\server_publishVehicle3.sqf"; //Used for car upgrades +if (DZE_VehicleKey_Changer) then { + server_publishVeh3 = compile preprocessFileLineNumbers "\z\addons\dayz_server\compile\server_publishVehicle3_vkc.sqf"; //Used for car upgrades +} else { + server_publishVeh3 = compile preprocessFileLineNumbers "\z\addons\dayz_server\compile\server_publishVehicle3.sqf"; //Used for car upgrades +}; server_tradeObj = compile preprocessFileLineNumbers "\z\addons\dayz_server\compile\server_tradeObject.sqf"; server_deaths = compile preprocessFileLineNumbers "\z\addons\dayz_server\compile\server_playerDeaths.sqf"; server_maintainArea = compile preprocessFileLineNumbers "\z\addons\dayz_server\compile\server_maintainArea.sqf"; diff --git a/Server Files/DZE_Server_Config/BattlEye/scripts.txt b/Server Files/DZE_Server_Config/BattlEye/scripts.txt index c04e6ca55..d6a9b25f7 100644 --- a/Server Files/DZE_Server_Config/BattlEye/scripts.txt +++ b/Server Files/DZE_Server_Config/BattlEye/scripts.txt @@ -14,14 +14,14 @@ 1 callExtension 1 camCreate !="_camera = \"camera\" camCreate [12222.323, 3415.7791, -0.059190542]" !"kdy = cos _dir * _size;\n_kdz = _size;\n\n\n_camera =" !="getPlayerUID player;\n_sourceID = \"0\";\n\n\n_camera = \"camera\" camCreate _deathPos;\n_camera camSetDir 0;\n_camera camSetFOV 1;\n_camer" 1 cameraEffect !"cameraEffect [\"Internal\",\"TOP\"];\n_camera camSetTarget _deathPos;\n_camera camSetPos [_deathPos select" !"r_Simulation\";\n\n_camera cameraEffect [\"Terminate" !"cameraEffect [\"internal\",\"back\"]\n\n_camera camPrepareTarget [6433.5" !"kdy = cos _dir * _size;\n_kdz = _size;\n\n\n_camera =" -1 cashMoney !="false];\n\nif (Z_SingleCurrency) then {\nplayer setVariable [\"cashMoney\", _characterCoins, true];\nplayer setVariable [\"globalMoney\"" !=" (Z_SingleCurrency) then {\n_wealth = player getVariable[([\"cashMoney\",\"globalMoney\"] select Z_persistentMoney),0];\nplayer setVar" !="ctrlSetText [13001,format [\"%1 %2\",[player getVariable [([\"cashMoney\",\"globalMoney\"] select Z_persistentMoney),0]] call BIS_fnc_" !="le [\"bodyName\",\"unknown\"];\n_hisMoney = _body getVariable [\"cashMoney\",0];\n\nif (isNil \"_hisMoney\") then {_hisMoney = 0;};\nif (!(t" !=" (!_canBuy) exitWith {}; \n\n_wealth = player getVariable[([\"cashMoney\",\"globalMoney\"] select Z_persistentMoney),0];\n\n_enoughMoney" !="if (Z_SingleCurrency) then {\n_coins = player getVariable [\"cashMoney\",0];\n_bankCoins = player getVariable [\"bankMoney\",0];\n_glob" !="l dayz_rollingMessages;};\n\n_hisMoney = _body getVariable [\"cashMoney\",0];\n\nif (_isZombie) then {\n_name = getText(configFile >> \"" !="wCurrencyUI) then {\nlocal _cashAmt = player getVariable[([\"cashMoney\",\"globalMoney\"] select Z_persistentMoney),0];\n_string = for" !=" = [false, [], [], [], 0];\n_wealth = player getVariable[([\"cashMoney\",\"globalMoney\"] select Z_persistentMoney),0];\n\nif (Z_Single" !="= [false, [], [], [], 0];\n_wealth = player getVariable [([\"cashMoney\",\"globalMoney\"] select Z_persistentMoney),0];\n\nif (Z_Single" +1 cashMoney !="false];\n\nif (Z_SingleCurrency) then {\nplayer setVariable [\"cashMoney\", _characterCoins, true];\nplayer setVariable [\"globalMoney\"" !=" (Z_SingleCurrency) then {\n_wealth = player getVariable[([\"cashMoney\",\"globalMoney\"] select Z_persistentMoney),0];\nplayer setVar" !="ctrlSetText [13001,format [\"%1 %2\",[player getVariable [([\"cashMoney\",\"globalMoney\"] select Z_persistentMoney),0]] call BIS_fnc_" !="le [\"bodyName\",\"unknown\"];\n_hisMoney = _body getVariable [\"cashMoney\",0];\n\nif (isNil \"_hisMoney\") then {_hisMoney = 0;};\nif (!(t" !=" (!_canBuy) exitWith {}; \n\n_wealth = player getVariable[([\"cashMoney\",\"globalMoney\"] select Z_persistentMoney),0];\n\n_enoughMoney" !="if (Z_SingleCurrency) then {\n_coins = player getVariable [\"cashMoney\",0];\n_bankCoins = player getVariable [\"bankMoney\",0];\n_glob" !="l dayz_rollingMessages;};\n\n_hisMoney = _body getVariable [\"cashMoney\",0];\n\nif (_isZombie) then {\n_name = getText(configFile >> \"" !="wCurrencyUI) then {\nlocal _cashAmt = player getVariable[([\"cashMoney\",\"globalMoney\"] select Z_persistentMoney),0];\n_string = for" !=" = [false, [], [], [], 0];\n_wealth = player getVariable[([\"cashMoney\",\"globalMoney\"] select Z_persistentMoney),0];\n\nif (Z_Single" !="= [false, [], [], [], 0];\n_wealth = player getVariable [([\"cashMoney\",\"globalMoney\"] select Z_persistentMoney),0];\n\nif (Z_Single" !="(Z_SingleCurrency) then {\n_wealth = player getVariable [([\"cashMoney\",\"globalMoney\"] select Z_persistentMoney),0];\n_enoughMoney " 1 clearMagazineCargo !="ddWeaponCargo\", \n\"addMagazine\", \n\"addMagazineCargo\", \n\"clearMagazineCargo\",\n\"clearWeaponCargo\",\n\"endMission\",\n\"failMission\",\n\"ti" !="rclearMagazineCargo = 'clearMagazineCargo'" !="rclearMagazineCargocode = compile preprocessFileLineNumbers (BIS_PathMPscriptCommands + 'clearMagazineCargo.sqf')" !=", \"addWeaponCargo\", \"addWPCur\", \"animate\", \"callVar\", \"clearMagazineCargo\", \"clearWeaponCargo\", \"createDiaryRecord\", \"createMark" !="rclearMagazineCargocode={diag_log(\"WARNING illegal RE rclearMagazineCargocode with args:\"+str(_this));};" !="eeSpace select 5;\n_normalWeaps = _freeSpace select 6;\n\nclearMagazineCargoGlobal _object;\nclearWeaponCargoGlobal _object;\n\n_retur" !=" {\n_bpMags = (getMagazineCargo (unitbackpack player));\nclearMagazineCargoGlobal (unitbackpack player);\n\n{\n_count = ((_bpMags sel" !="o {\n\n_ok = false;\n_mags = getMagazineCargo _firePlace;\nclearMagazineCargoGlobal _firePlace;\n\n_fuel = [\"PartWoodPile\",\"ItemLog\",\"" 1 clearWeaponCargo !="Magazine\", \n\"addMagazineCargo\", \n\"clearMagazineCargo\",\n\"clearWeaponCargo\",\n\"endMission\",\n\"failMission\",\n\"titleCut\", \n\"titleText\"" !="rclearWeaponCargo = 'clearWeaponCargo'" !="rclearWeaponCargocode = compile preprocessFileLineNumbers (BIS_PathMPscriptCommands + 'clearWeaponCargo.sqf')" !="addWPCur\", \"animate\", \"callVar\", \"clearMagazineCargo\", \"clearWeaponCargo\", \"createDiaryRecord\", \"createMarkerLocal\", \"createSimp" !="rclearWeaponCargocode={diag_log(\"WARNING illegal RE rclearWeaponCargocode with args:\"+str(_this));};" !="_freeSpace select 6;\n\nclearMagazineCargoGlobal _object;\nclearWeaponCargoGlobal _object;\n\n_returnVar = [];\n_returnMag = [];\n_retu" 1 clearBackpackCargo 1 closeDisplay !"'closeDisplay'" !"closeDisplay 0" !"closeDisplay 2" !"if (!isNil \"closeDisplay\") then {" 1 compile !"ca\\communityconfiguration" !"ca\\Data\\" !"ca\\missions" !"ca\\modules" !"ca\\ui\\" !"ca\\Warfare2\\" !"scriptName \"Functions\\systems\\fn_inv" !"scriptName \"MP\\data\\script" !"code = compile preprocessFileLineNumbers (BIS_PathMPscriptCommands" !"t = missionConfigFile >> \"onMinimapScript" !="_this call (call compile GetText (configFile >> \"CfgAmmo\" >> _amm >> \"muzzleEffect\"));" !"z\\addons\\dayz_code\\" !"_menu ctrlSetEventHandler [\"ButtonClick\",_compile];\n};\n_pos set [3" !"{ _x set [1, compile (_x select 1)]; }" !"silver_1oz_b);\n\n{ \nif (!isNil {call compile" !"Var = compile format[\"epoch_death_board_record_" !="RandomSentenceFunc\") then \n{\nBIS_selectRandomSentenceFunc = compile (preprocessFileLineNumbers \"ca\\characters_e\\data\\scripts\\sel" 1 createAgent !="_agent = if (_type == \"Pastor\") then {createAgent [_type, _Pos, [], 0, \"NONE\"]} else {createAgent [_type, _Pos, [], 0, \"FORM\"]};" !="_dog = createAgent [_type, _Pos, [], 0, \"NONE\"];" !="\n\n\n_type = _unitTypes call BIS_fnc_selectRandom;\n_agent = createAgent [_type, _position, [], 0, \"CAN_COLLIDE\"];\n_agent setDir (r" -1 createDialog !="_region = createDialog \"RscDisplaySpawnSelecter\";" !="_gender = createDialog 'RscDisplayGenderSelect';" !="_dialog = createDialog \"bloodTest\";" !"createDialog 'horde_journal_" !"Z_ResetContainer = true;\ncreateDialog \"AdvancedTrading\";" !"createDialog \"DoorManagement\";\ncall DoorNearbyHumans;" !="createDialog \"ComboLockUI\";" !"createdialog \"PlotManagement\";\ncall PlotNearbyHumans;" !"_ok = createDialog \"KeypadUI\";" !"EpochDeathBoardLoad = {\ncreatedialog \"EpochDeathBoardDialog\";" !="if(DZE_doorManagement) then {createdialog \"DoorAccess\";} else {createdialog \"ComboLockUI\";};" !"\ndisableSerialization;\ncreateDialog \"DZ_GroupDialog\";" !"createDialog _dialog;\n\nwaitUntil {!dialog};\n\nif (keypadCancel) exitWith {" !=";\n};\n\nZSC_CurrentStorage setVariable[\"isBusy\",true,true];\ncreateDialog \"BankDialog\";\ncall BankDialogUpdateAmounts;\n\nwaitUntil {!" !="ANKING_NOT_AVAIL\",_typeOf] call dayz_rollingMessages;\n};\n\ncreateDialog \"atmDialog\";\ncall AtmDialogUpdateAmounts;\n\nwaitUntil {!di" !="!_isBusy) then {\nplayer setVariable[\"isBusy\",true,true]; \ncreateDialog \"GivePlayerDialog\";\n_display = uiNamespace getVariable[\"z" !="ked\",\"VaultStorage2\",\"TallSafe\",\"TallSafeLocked\"]) then {\ncreateDialog \"SafeKeyPad\";\n} else {\ncreateDialog \"KeypadUI\";\n};\n};\n\nda" !";\n\nif (count rv_vehicleList > 1) then {\nrv_isOk = false;\n\ncreateDialog \"remoteVehicle\";\n\n_display = uiNamespace getVariable[\"rv_" +1 createDialog !="_region = createDialog \"RscDisplaySpawnSelecter\";" !="_gender = createDialog 'RscDisplayGenderSelect';" !="_dialog = createDialog \"bloodTest\";" !"createDialog 'horde_journal_" !"Z_ResetContainer = true;\ncreateDialog \"AdvancedTrading\";" !"createDialog \"DoorManagement\";\ncall DoorNearbyHumans;" !="createDialog \"ComboLockUI\";" !"createdialog \"PlotManagement\";\ncall PlotNearbyHumans;" !"_ok = createDialog \"KeypadUI\";" !"EpochDeathBoardLoad = {\ncreatedialog \"EpochDeathBoardDialog\";" !="if(DZE_doorManagement) then {createdialog \"DoorAccess\";} else {createdialog \"ComboLockUI\";};" !"\ndisableSerialization;\ncreateDialog \"DZ_GroupDialog\";" !"createDialog _dialog;\n\nwaitUntil {!dialog};\n\nif (keypadCancel) exitWith {" !=";\n};\n\nZSC_CurrentStorage setVariable[\"isBusy\",true,true];\ncreateDialog \"BankDialog\";\ncall BankDialogUpdateAmounts;\n\nwaitUntil {!" !="ANKING_NOT_AVAIL\",_typeOf] call dayz_rollingMessages;\n};\n\ncreateDialog \"atmDialog\";\ncall AtmDialogUpdateAmounts;\n\nwaitUntil {!di" !="!_isBusy) then {\nplayer setVariable[\"isBusy\",true,true]; \ncreateDialog \"GivePlayerDialog\";\n_display = uiNamespace getVariable[\"z" !="ked\",\"VaultStorage2\",\"TallSafe\",\"TallSafeLocked\"]) then {\ncreateDialog \"SafeKeyPad\";\n} else {\ncreateDialog \"KeypadUI\";\n};\n};\n\nda" !";\n\nif (count rv_vehicleList > 1) then {\nrv_isOk = false;\n\ncreateDialog \"remoteVehicle\";\n\n_display = uiNamespace getVariable[\"rv_" !="urrencyName]} else {[_amount,true] call z_calcCurrency};\n\ncreateDialog \"vkc\";\n{ctrlShow [_x,false]} count [4803,4850,4851];\n\ncal" 1 createDisplay 1 createMarker !"\"createMarkerLocal\"," !"rcreateMarkerLocal" !"if (isnil 'BIS_GITA_fnc_createMarkers' || false) then {" !"_marker = createMarkerLocal [format[\"groupMember" !">> \"CfgVehicles\" >> _vehicle >> \"displayName\");\n_marker = createMarkerLocal [\"vehicleMarker\" + (str _i),[_position select 0,_pos" 1 createUnit !="_newUnit = _group createUnit [_class,respawn_west_original,[],0,\"NONE\"];" !="BIS_MPF_logic = BIS_MPF_dummygroup createUnit [\"Logic\", [1000,10,0], [], 0, \"NONE\"];" @@ -40,17 +40,17 @@ 1 execVM !"rexecVM" !"\"execVM\", " !="[] execVM \"initJIPcompatible.sqf\";" !="_script = [] execVM (BIS_MP_Path + BIS_PATH_SQF + \"JIPWaitFor.sqf\");" !"execVM \"\\ca\\Data\\" !"execVM '\\ca\\Data\\" !"execVM \"\\ca\\missions" !"execVM 'ca\\modules\\" !"execVM \"ca\\modules\\" !"'\\ca\\ui\\" !"\"\\ca\\ui\\" !"scriptName \"MP\\data\\script" !"_handle\"];\n_handle = [_display] execVM _script;\n}" !"execVM '\\z\\addons\\dayz_code\\" !"execVM 'z\\addons\\dayz_code\\" !"execVM \"z\\addons\\dayz_code\\" !"execVM \"\\z\\addons\\dayz_code\\" !"execVM (\"\\z\\addons\\dayz_code\\" !="dayz_rulesHandle = execVM \"rules.sqf\";" !"execvm '\\ASC\\" !"\\usec_ch53\\scripts\\" !"execVM (_actionDir + \"warn.sqf" !="_this execVM \"\\GNT_C185\\scr\\C185_Exhaust.sqf\";[_this select 0] execvm \"\\GNT_C185\\scr\\G_CheckEngine.sqf\";" 1 failMission !"rfailMission" !"failMission\",\n\"titleCut\"," !"fadeSound\", \"failMission\"," !"if (_debug == 1) then {\ndiag_log (\"End Mission\");\n};\n\nfailMission" 1 forceEnd -1 globalMoney !="\"cashMoney\", _characterCoins, true];\nplayer setVariable [\"globalMoney\", _globalCoins, true];\nplayer setVariable [\"bankMoney\", _b" !="rency) then {\n_wealth = player getVariable[([\"cashMoney\",\"globalMoney\"] select Z_persistentMoney),0];\nplayer setVariable[([\"cash" !="13001,format [\"%1 %2\",[player getVariable [([\"cashMoney\",\"globalMoney\"] select Z_persistentMoney),0]] call BIS_fnc_numberText,Cu" !="Messages};\n\n_myMoney = player getVariable [([\"cashMoney\",\"globalMoney\"] select Z_persistentMoney),0];\n_myMoney = _myMoney + _his" !="xitWith {}; \n\n_wealth = player getVariable[([\"cashMoney\",\"globalMoney\"] select Z_persistentMoney),0];\n\n_enoughMoney = false;\n\n_m" !="able [\"bankMoney\",0];\n_globalCoins = player getVariable [\"globalMoney\",0];\n};\n\n\n[_model, _charID, _humanity, _zombieKills, _head" !="then {\nlocal _cashAmt = player getVariable[([\"cashMoney\",\"globalMoney\"] select Z_persistentMoney),0];\n_string = format [\"=" 1 groupIcon 1 HelicopterExplo !"(isNull _who) then {\nif (_ammo != \"\" && _ammo isKindOf \"HelicopterExplo" !"_v = thisTrigger getVariable [\"obj\", objNull];\n" !"_v = thisTrigger getVariable [\"\"obj\"\", objNull];\n" !"\n\n\nremoveallweapons _v;\n\nif (local _v) then {_expl=\"HelicopterExplo" 1 hideObject !"rhideObject" !"\"hideObject\"" !"(_x select 0) nearestObject (_x select 1);\n_object hideObject" !"_object2 = _ghost2 createVehicleLocal [0,0,0];\nhideObject _object;" 1 hint !", \"_postFix\"" !rhint !rtaskHint !"\"hint\", " !"\"hintC\", " !"\"taskHint\"," !"_controlHintButton ctrlSettext \"Objectives\";" !"hint (localize \"strwf" !"'BIS_fnc_hints'" !sched_planthint !"call ui_initDisplay;\nhintSilent \"\"" !"hintSilent localize \"str_player_low" !=" select 1;\n_filter = [\"private\",\"dynamic_text\",\"ai_killfeed\",\"hintWithImage\",\"hintNoImage\"]; \n\nif (typeName _message == \"TEXT\") " !="vars select 7) \n] spawn BIS_fnc_dynamicText;\n};\nif (_type == \"hintWithImage\") exitWith {hint parseText format[\"> \"CfgVehicles\" >>" !="#line 1 \"z\\addons\\dayz_code\\compile\\player_humanityChange.sqf\"\nprivate [\"_change\",\"_humanity\"];\n\n\n\n\n_change = _this;\n\n_humanity " !"layer]];\npublicVariableServer \"PVDZ_send\";\n\n\n20 call player_humanityChange;\n\nformat[localize \"str_actions_medical_gave_wipes\",(n" !=" [\"_msg\",\"_bagUsed\",\"_bloodResult\",\"_bloodAmount\",\"_unit\",\"_humanityAwarded\",\"_timer\",\"_i\",\"_isClose\",\"_duration\",\"_rhVal\",\"_blo" !="#line 1 \"z\\addons\\dayz_code\\compile\\player_humanityMorph.sqf\"\ncloseDialog 0;\nlocal _charID = _this select 1;\nlocal _model = _thi" !="ody_Value} else {DZE_Butcher_Body_Value};\n_gain call player_humanityChange;\n\ndayz_actionInProgress = false;\n" !="l fn_dynamicTool;\n\ncall {\nif (_isZombie) exitWith {\n\nlocal _humanity = player getVariable [\"humanity\",0];\nplayer setVariable [\"h" -1 lbCurSel !"_selectedUserIndex = lbCurSel _lbUsersControl;" !="profileNamespace setVariable ['statusUI',(lbCurSel (_this select 0))];" !="profileNamespace setVariable ['streamerMode',(lbCurSel (_this select 0))];" !"_index = lbCurSel _lbcontrol;\n_selectedItem" !"_selected = lbCurSel _list;\n_classname = _list lnbData [_selected, 2];" !="_friendName = _userList lbText (lbCurSel _userList);" !")] call Z_" !"(lbCurSel 7421) call Z_fillCategoryList" !"] call Door" !"] call Plot" !"[(lbCurSel 12001)] " !="[(lbCurSel 21000), ((ctrlParent (_this select 0)) displayCtrl 21001)] spawn EpochDeathBoardClick;" !"((ctrlParent (_this select 0)) closeDisplay 2);" !="_uid = _playerList lbData (lbCurSel _playerList);" !"_myGroup lbData (lbCurSel _myGroup);" -1 lbSet !"_lbUsersControl lbSetColor [_x, [1,0,0,1]];" !"\n_control lbSetColor [_x, _color];\n};" !"_weaponsLBSetFocus" !="(_this select 0) displayCtrl _idc lbSetCurSel (profileNamespace getVariable [_var,_default]);" !="(_display displayCtrl 105) lbSetColor [_i, [0.06, 0.05, 0.03, 1]];" !" [7421," !"lbSetPicture [7422, _index" !"lbSetPicture [7402, _index" !"lbSetPicture [7401, _index" !="_userList lbSetData [(lbSize _userList) -1,_friendUID];" !" [TraderDialogItemList, _index, " !"_myGroup lbSetData [_index,getPlayerUID _x];" !"ive DZE_myVehicle} && {DZE_myVehicle == _x}) then {\n_control lbSetColor [(lbSize _control)-1,[0, 1, 0, 1]];\n};\n} count rv_vehicl" +1 lbCurSel !"_selectedUserIndex = lbCurSel _lbUsersControl;" !="profileNamespace setVariable ['statusUI',(lbCurSel (_this select 0))];" !="profileNamespace setVariable ['streamerMode',(lbCurSel (_this select 0))];" !"_index = lbCurSel _lbcontrol;\n_selectedItem" !"_selected = lbCurSel _list;\n_classname = _list lnbData [_selected, 2];" !="_friendName = _userList lbText (lbCurSel _userList);" !")] call Z_" !"(lbCurSel 7421) call Z_fillCategoryList" !"] call Door" !"] call Plot" !"[(lbCurSel 12001)] " !="[(lbCurSel 21000), ((ctrlParent (_this select 0)) displayCtrl 21001)] spawn EpochDeathBoardClick;" !"((ctrlParent (_this select 0)) closeDisplay 2);" !="_uid = _playerList lbData (lbCurSel _playerList);" !"_myGroup lbData (lbCurSel _myGroup);" !="vkc_charID = (vkc_keyList select 0) select (lbCurSel 4802);vkc_keyName = (vkc_keyList select 1) select (lbCurSel 4802);" +1 lbSet !"_lbUsersControl lbSetColor [_x, [1,0,0,1]];" !"\n_control lbSetColor [_x, _color];\n};" !"_weaponsLBSetFocus" !="(_this select 0) displayCtrl _idc lbSetCurSel (profileNamespace getVariable [_var,_default]);" !="(_display displayCtrl 105) lbSetColor [_i, [0.06, 0.05, 0.03, 1]];" !" [7421," !"lbSetPicture [7422, _index" !"lbSetPicture [7402, _index" !"lbSetPicture [7401, _index" !="_userList lbSetData [(lbSize _userList) -1,_friendUID];" !" [TraderDialogItemList, _index, " !"_myGroup lbSetData [_index,getPlayerUID _x];" !"ive DZE_myVehicle} && {DZE_myVehicle == _x}) then {\n_control lbSetColor [(lbSize _control)-1,[0, 1, 0, 1]];\n};\n} count rv_vehicl" !="bAdd ((vkc_keyList select 1) select _forEachIndex);\n_control lbSetPicture [_index,getText(configFile >> \"CfgWeapons\" >> ((vkc_ke" 1 loadFile 1 menu !",\"MenuSelected\",\"Draw\",\"VideoStop" !"_menu = _parent displayCtrl (1600 + _i);\n_menu ctrlShow " !"BIS_fnc_commsMenu" !"BIS_fnc_kbMenu" !"call gear_ui_offMenu;" !"dayz_inflame_showMenu" !"\"showCommandingMenu\", " !"rshowCommandingMenu" !"menu_" !"use action menu to " !"\"_menu\",\"_menu1\"" !"fn_gearMenuChecks" !"fn_pauseMenuChecks" -1 nearEntities !="exit = true;\n} else {\n_nearestObjects = (position player) nearEntities [[\"Air\", \"Car\", \"Motorcycle\", \"Tank\", \"Ship\"], 26];\nif (c" !="jects \"SpawnableWreck\";\n{deleteVehicle _x} count (_setPos nearEntities [\"zZombie_Base\",30]);\nplayer setDir _setDir;\n\nif (dayz_pa" !="((!surfaceIsWater _Pos) AND {(0 == {alive _x} count (_Pos nearEntities [ AllPlayers, 200 ]))}) then {\n_agent = if (_type == \"Pas" !="z, _elevation] ];\n};\n};\n};\n};\n} count ((getPosATL player) nearEntities [\"zZombie_Base\", 30]);\n};\n\n\n_buriedZeds\n};\n" !="call dz_fn_array_any);\n};\n\n_vehClose = (getPosATL player) nearEntities [[\"Car\",\"Tank\",\"Helicopter\",\"Plane\",\"StaticWeapon\",\"Ship\"" !="z_spawnZombies = {alive _x AND local _x} count (_position nearEntities [\"zZombie_Base\",_radius]);\ndayz_CurrentNearByZombies = {a" !="{\nr_player_infected = true;\n\n};\n};\n};\n} count (_mylastPos nearEntities [\"CAManBase\",12]);\nif (dayz_temperatur < ((50 / 100) * (d" !=" < dayz_maxGlobalZeds}) then {\n_zombiesNum = count (_bPos nearEntities [\"zZombie_Base\",(((sizeOf _type) * 2) + 10)]);\nif (_zombi" !="te;\n};\n};\n\n\n_nearByPlayer = ({isPlayer _x} count (_objPos nearEntities [\"CAManBase\",30])) > 0;\nif (!_nearByPlayer) then {\n_posit" !="_entityTime = diag_tickTime;\n\n_list = (getposATL _agent) nearEntities [[\"CAManBase\",\"AllVehicles\"],300];\n_isSomeone = ({isPlayer" !="_timeN = diag_tickTime;\n\n_list = (getposATL _agent) nearEntities [[\"CAManBase\",\"AllVehicles\"],300];\n_isSomeone = ({isPlayer _x} " !="_waitStart = diag_tickTime;\n\n_list = (getposATL _agent) nearEntities [[\"CAManBase\",\"AllVehicles\"],300];\n_isSomeone = ({isPlayer " !="lt = false;\n_pos = [player] call FNC_GetPos;\n_list = _pos nearEntities [[\"Air\",\"LandVehicle\",\"Ship\"],Z_VehicleDistance];\n\nif (!i" !="[\"localtargets\",_localtargets,false];\n};\n};\n} count (_pos nearEntities [\"zZombie_Base\",50]);\n} else {\nwhile {alive _projectile} " !="this select 2;\n_pos = _this select 3;\n\n_listTalk = _pos nearEntities [\"zZombie_Base\",_distance];\n\n{\n_distance = _distance max " !="_list = (getposATL _agent) nearEntities [[\"CAManBase\",\"AllVehicles\"],300];\n_isSomeone = ({isPlayer _x} count _list) > 0;\n\n_timeN" !=";};\n\n_playerNear = {isPlayer _x} count ((getPosATL _body) nearEntities [\"CAManBase\", 10]) > 1;\nif (_playerNear) exitWith {dayz_a" !="\n\n\n_pos = getPosATL player;\nif ({isPlayer _x} count (_pos nearEntities [\"CAManBase\",40]) > 1) then {\n[_unit,\"hit\",0,false] call " !="[];\n\n_PlayerNear = {isPlayer _x} count ((getPosATL _item) nearEntities [\"CAManBase\", 12]) > 1;\nif (_PlayerNear) exitWith {locali" !="layerNear = {isPlayer _x} count (([_obj] call FNC_GetPos) nearEntities [\"CAManBase\", 12]) > 1;\nif (_PlayerNear && (_isMine or _o" !="hicle _player] call FNC_getPos;\n\n\n_findNearestPole = _pos nearEntities [\"Plastic_Pole_EP1_DZ\", _distance];\n\n_IsNearPlot = count " !="layerNear = {isPlayer _x} count ((getPosATL cursortarget) nearEntities [\"CAManBase\", 10]) > 1;\nif (_playerNear) exitWith {\ndayz_" !="etPos;\n\nif (surfaceIsWater _location && {count (_location nearEntities [\"Ship\",8]) > 0}) then {\ndeleteVehicle _sign;\nlocalize \"S" !="yerNear = {isPlayer _x} count (([player] call FNC_GetPos) nearEntities [\"CAManBase\", 12]) > 1;\nif (_playerNear) exitWith {locali" !="ag_tickTime);\n_playerCheck = ({isPlayer _x} count (player nearEntities [\"AllVehicles\",5]) > 1);\n_zedCheck = ((count (player near" !="(_this select 1) && isServer && (({isPlayer _x} count (_z nearEntities ['CAManBase',150])) == 0)) exitWith { _z call sched_co_de" !=" do {\nuiSleep 5;\n};\nhideBody _body;\n\n\n\n\n\n\n_inRange = _pos nearEntities [\"CAManBase\",100];\n{\nif ((isPlayer _x) && {_x != player})" !=" {\n_PlayerNear = {isPlayer _x} count ((getPosATL _holder) nearEntities [\"CAManBase\", 12]) > 1;\nif (_PlayerNear) exitWith {locali" !="yerNear = {isPlayer _x} count (([_plant] call FNC_GetPos) nearEntities [\"CAManBase\", 12]) > 1;\nif (_playerNear) exitWith {dayz_a" !="layerNear = {isPlayer _x} count (([_obj] call FNC_GetPos) nearEntities [\"CAManBase\", 12]) > 1;\nif (_playerNear) exitWith {dayz_a" !="\n_ammo = \"RunOver\";\n};\n} count (([_unit] call fnc_getPos) nearEntities [[\"Air\",\"LandVehicle\",\"Ship\"],3]);\n};\n};\n};\n\n_end = false" !="{\n_liftHeli = _x;\n_found = true;\n};\n};\n};\n} count (player nearEntities [DZE_HeliAllowTowFrom,15]);\n};\n\nlocal _attached = _cursor" !="z_fn_array_any);\n};\n\nlocal _vehClose = (getPosATL player) nearEntities [[\"Car\",\"Tank\",\"Helicopter\",\"Plane\",\"StaticWeapon\",\"Ship\"" !=" = false;\n\nif (!isNull _this) then {\n_nearPlayers = _this nearEntities [\"CAManBase\", 12];\n_playerNear = ({isPlayer _x} count _ne" !="ePeople = if (DZE_doorManagementMustBeClose) then {player nearEntities [\"CAManBase\", 12]} else {playableUnits};\n\n{\nif (isPlayer " !"\n\n_PlayerNear = {isPlayer _x} count ((getPosATL _vehicle) nearEntities [\"CAManBase\", 12]) > 1;\nif (_PlayerNear) exitWith {" !="layerNear = {isPlayer _x} count (([_obj] call FNC_GetPos) nearEntities [\"CAManBase\", 10]) > 1;\nif (_playerNear) exitWith {dayz_a" !"arestVehicle),_x];\n};\n} count (([player] call fnc_getPos) nearEntities [[\"Air\",\"LandVehicle\",\"Ship\"],30]);\n\nif (count _findNeare" !"arPlayers = {(isPlayer _x && _x != player)} count (player nearEntities [\"CAManBase\",8]);\n\nif (!(_object isKindOf \"ATV_Base_EP1\")" !="ePeople = if (DZE_plotManagementMustBeClose) then {player nearEntities [\"CAManBase\", 12]} else {playableUnits};\n\n{\nif (isPlayer " !="lot\"];\n\nlbClear 7002;\n_plots = ([player] call FNC_getPos) nearEntities [\"Plastic_Pole_EP1_DZ\",15];\n_thePlot = _plots select 0;\n_" !="_area_preview = 1;\n\n_target = (([player] call FNC_getPos) nearEntities [\"Plastic_Pole_EP1_DZ\",15]) select 0;\n_objects = nearestO" !="_PlotPole select 0;\n_target = (([player] call FNC_getPos) nearEntities [\"Plastic_Pole_EP1_DZ\",15]) select 0;\n\n_buildables = DZE_" !=" == \"\") exitWith {};\n\n_plots = ([player] call FNC_getPos) nearEntities [\"Plastic_Pole_EP1_DZ\",15];\n\n_thePlot = _plots select 0;\n" !="here100cm_EP1\"; \n\n\n_thePlot = (([player] call FNC_getPos) nearEntities [\"Plastic_Pole_EP1_DZ\",15]) select 0;\n_center = getPosASL" !"arPlayers = {(isPlayer _x && _x != player)} count (player nearEntities [\"CAManBase\",8]);\n\nif ((_object isKindOf \"C130J_US_EP1\" o" !="RANGE = 1500;};CA_ZOMBIE_COUNT = count ((position player) nearEntities ['zZombie_Base',CA_GPS_RANGE]); CA_MAN_COUNT = count ((po" !"ayerNear = {isPlayer _x} count (([_body] call FNC_GetPos) nearEntities [\"CAManBase\", 10]) > 1;\nif (_playerNear) exitWith {dayz_a" !="\n_x setVariable [\"myDest\",_pos,true];\n};\n};\n} count (_pos nearEntities [\"Zed_Base\",_distance]);\n" !=" then {deleteVehicle _x}; \n} forEach ((getPosATL _refObj) nearEntities [\"Zed_Base\",100]);\n\nif (_attacked) then {\nif (r_player_un" !="erNear = {isPlayer _x} count (([_corpse] call FNC_GetPos) nearEntities [\"CAManBase\", 10]) > 1;\nif (_playerNear) exitWith {dayz_a" !="ss = false;}; \nif ({isPlayer _x} count ((getPosATL _body) nearEntities [\"CAManBase\", 12]) > 1) exitWith {dayz_actionInProgress =" +1 nearEntities !="exit = true;\n} else {\n_nearestObjects = (position player) nearEntities [[\"Air\", \"Car\", \"Motorcycle\", \"Tank\", \"Ship\"], 26];\nif (c" !="jects \"SpawnableWreck\";\n{deleteVehicle _x} count (_setPos nearEntities [\"zZombie_Base\",30]);\nplayer setDir _setDir;\n\nif (dayz_pa" !="((!surfaceIsWater _Pos) AND {(0 == {alive _x} count (_Pos nearEntities [ AllPlayers, 200 ]))}) then {\n_agent = if (_type == \"Pas" !="z, _elevation] ];\n};\n};\n};\n};\n} count ((getPosATL player) nearEntities [\"zZombie_Base\", 30]);\n};\n\n\n_buriedZeds\n};\n" !="call dz_fn_array_any);\n};\n\n_vehClose = (getPosATL player) nearEntities [[\"Car\",\"Tank\",\"Helicopter\",\"Plane\",\"StaticWeapon\",\"Ship\"" !="z_spawnZombies = {alive _x AND local _x} count (_position nearEntities [\"zZombie_Base\",_radius]);\ndayz_CurrentNearByZombies = {a" !="{\nr_player_infected = true;\n\n};\n};\n};\n} count (_mylastPos nearEntities [\"CAManBase\",12]);\nif (dayz_temperatur < ((50 / 100) * (d" !=" < dayz_maxGlobalZeds}) then {\n_zombiesNum = count (_bPos nearEntities [\"zZombie_Base\",(((sizeOf _type) * 2) + 10)]);\nif (_zombi" !="te;\n};\n};\n\n\n_nearByPlayer = ({isPlayer _x} count (_objPos nearEntities [\"CAManBase\",30])) > 0;\nif (!_nearByPlayer) then {\n_posit" !="_entityTime = diag_tickTime;\n\n_list = (getposATL _agent) nearEntities [[\"CAManBase\",\"AllVehicles\"],300];\n_isSomeone = ({isPlayer" !="_timeN = diag_tickTime;\n\n_list = (getposATL _agent) nearEntities [[\"CAManBase\",\"AllVehicles\"],300];\n_isSomeone = ({isPlayer _x} " !="_waitStart = diag_tickTime;\n\n_list = (getposATL _agent) nearEntities [[\"CAManBase\",\"AllVehicles\"],300];\n_isSomeone = ({isPlayer " !="lt = false;\n_pos = [player] call FNC_GetPos;\n_list = _pos nearEntities [[\"Air\",\"LandVehicle\",\"Ship\"],Z_VehicleDistance];\n\nif (!i" !="[\"localtargets\",_localtargets,false];\n};\n};\n} count (_pos nearEntities [\"zZombie_Base\",50]);\n} else {\nwhile {alive _projectile} " !="this select 2;\n_pos = _this select 3;\n\n_listTalk = _pos nearEntities [\"zZombie_Base\",_distance];\n\n{\n_distance = _distance max " !="_list = (getposATL _agent) nearEntities [[\"CAManBase\",\"AllVehicles\"],300];\n_isSomeone = ({isPlayer _x} count _list) > 0;\n\n_timeN" !=";};\n\n_playerNear = {isPlayer _x} count ((getPosATL _body) nearEntities [\"CAManBase\", 10]) > 1;\nif (_playerNear) exitWith {dayz_a" !="\n\n\n_pos = getPosATL player;\nif ({isPlayer _x} count (_pos nearEntities [\"CAManBase\",40]) > 1) then {\n[_unit,\"hit\",0,false] call " !="[];\n\n_PlayerNear = {isPlayer _x} count ((getPosATL _item) nearEntities [\"CAManBase\", 12]) > 1;\nif (_PlayerNear) exitWith {locali" !="layerNear = {isPlayer _x} count (([_obj] call FNC_GetPos) nearEntities [\"CAManBase\", 12]) > 1;\nif (_PlayerNear && (_isMine or _o" !="hicle _player] call FNC_getPos;\n\n\n_findNearestPole = _pos nearEntities [\"Plastic_Pole_EP1_DZ\", _distance];\n\n_IsNearPlot = count " !="layerNear = {isPlayer _x} count ((getPosATL cursortarget) nearEntities [\"CAManBase\", 10]) > 1;\nif (_playerNear) exitWith {\ndayz_" !="etPos;\n\nif (surfaceIsWater _location && {count (_location nearEntities [\"Ship\",8]) > 0}) then {\ndeleteVehicle _sign;\nlocalize \"S" !="yerNear = {isPlayer _x} count (([player] call FNC_GetPos) nearEntities [\"CAManBase\", 12]) > 1;\nif (_playerNear) exitWith {locali" !="ag_tickTime);\n_playerCheck = ({isPlayer _x} count (player nearEntities [\"AllVehicles\",5]) > 1);\n_zedCheck = ((count (player near" !="(_this select 1) && isServer && (({isPlayer _x} count (_z nearEntities ['CAManBase',150])) == 0)) exitWith { _z call sched_co_de" !=" do {\nuiSleep 5;\n};\nhideBody _body;\n\n\n\n\n\n\n_inRange = _pos nearEntities [\"CAManBase\",100];\n{\nif ((isPlayer _x) && {_x != player})" !=" {\n_PlayerNear = {isPlayer _x} count ((getPosATL _holder) nearEntities [\"CAManBase\", 12]) > 1;\nif (_PlayerNear) exitWith {locali" !="yerNear = {isPlayer _x} count (([_plant] call FNC_GetPos) nearEntities [\"CAManBase\", 12]) > 1;\nif (_playerNear) exitWith {dayz_a" !="layerNear = {isPlayer _x} count (([_obj] call FNC_GetPos) nearEntities [\"CAManBase\", 12]) > 1;\nif (_playerNear) exitWith {dayz_a" !="\n_ammo = \"RunOver\";\n};\n} count (([_unit] call fnc_getPos) nearEntities [[\"Air\",\"LandVehicle\",\"Ship\"],3]);\n};\n};\n};\n\n_end = false" !="{\n_liftHeli = _x;\n_found = true;\n};\n};\n};\n} count (player nearEntities [DZE_HeliAllowTowFrom,15]);\n};\n\nlocal _attached = _cursor" !="z_fn_array_any);\n};\n\nlocal _vehClose = (getPosATL player) nearEntities [[\"Car\",\"Tank\",\"Helicopter\",\"Plane\",\"StaticWeapon\",\"Ship\"" !=" = false;\n\nif (!isNull _this) then {\n_nearPlayers = _this nearEntities [\"CAManBase\", 12];\n_playerNear = ({isPlayer _x} count _ne" !="ePeople = if (DZE_doorManagementMustBeClose) then {player nearEntities [\"CAManBase\", 12]} else {playableUnits};\n\n{\nif (isPlayer " !"\n\n_PlayerNear = {isPlayer _x} count ((getPosATL _vehicle) nearEntities [\"CAManBase\", 12]) > 1;\nif (_PlayerNear) exitWith {" !="layerNear = {isPlayer _x} count (([_obj] call FNC_GetPos) nearEntities [\"CAManBase\", 10]) > 1;\nif (_playerNear) exitWith {dayz_a" !"arestVehicle),_x];\n};\n} count (([player] call fnc_getPos) nearEntities [[\"Air\",\"LandVehicle\",\"Ship\"],30]);\n\nif (count _findNeare" !"arPlayers = {(isPlayer _x && _x != player)} count (player nearEntities [\"CAManBase\",8]);\n\nif (!(_object isKindOf \"ATV_Base_EP1\")" !="ePeople = if (DZE_plotManagementMustBeClose) then {player nearEntities [\"CAManBase\", 12]} else {playableUnits};\n\n{\nif (isPlayer " !="lot\"];\n\nlbClear 7002;\n_plots = ([player] call FNC_getPos) nearEntities [\"Plastic_Pole_EP1_DZ\",15];\n_thePlot = _plots select 0;\n_" !="_area_preview = 1;\n\n_target = (([player] call FNC_getPos) nearEntities [\"Plastic_Pole_EP1_DZ\",15]) select 0;\n_objects = nearestO" !="_PlotPole select 0;\n_target = (([player] call FNC_getPos) nearEntities [\"Plastic_Pole_EP1_DZ\",15]) select 0;\n\n_buildables = DZE_" !=" == \"\") exitWith {};\n\n_plots = ([player] call FNC_getPos) nearEntities [\"Plastic_Pole_EP1_DZ\",15];\n\n_thePlot = _plots select 0;\n" !="here100cm_EP1\"; \n\n\n_thePlot = (([player] call FNC_getPos) nearEntities [\"Plastic_Pole_EP1_DZ\",15]) select 0;\n_center = getPosASL" !"arPlayers = {(isPlayer _x && _x != player)} count (player nearEntities [\"CAManBase\",8]);\n\nif ((_object isKindOf \"C130J_US_EP1\" o" !="RANGE = 1500;};CA_ZOMBIE_COUNT = count ((position player) nearEntities ['zZombie_Base',CA_GPS_RANGE]); CA_MAN_COUNT = count ((po" !"ayerNear = {isPlayer _x} count (([_body] call FNC_GetPos) nearEntities [\"CAManBase\", 10]) > 1;\nif (_playerNear) exitWith {dayz_a" !="\n_x setVariable [\"myDest\",_pos,true];\n};\n};\n} count (_pos nearEntities [\"Zed_Base\",_distance]);\n" !=" then {deleteVehicle _x}; \n} forEach ((getPosATL _refObj) nearEntities [\"Zed_Base\",100]);\n\nif (_attacked) then {\nif (r_player_un" !="erNear = {isPlayer _x} count (([_corpse] call FNC_GetPos) nearEntities [\"CAManBase\", 10]) > 1;\nif (_playerNear) exitWith {dayz_a" !="ss = false;}; \nif ({isPlayer _x} count ((getPosATL _body) nearEntities [\"CAManBase\", 12]) > 1) exitWith {dayz_actionInProgress =" !="{isPlayer _x} count (([vkc_cursorTarget] call FNC_GetPos) nearEntities [\"CAManBase\", 10]) > 1;\nif (_playerNear) exitWith {call _" 1 nearestObject !="licVariableEventHandler {_pos = (_this select 1); _obj = nearestObjects [_pos, DZE_isWreckBuilding, 5]; if (count _obj > 0) then" !=" 0;\n_whatIwant = _this select 1;\n_ret = false;\n\n_flame = nearestObjects [_fireplace, [\"flamable_DZ\"], 1];\n_flame = if (count _fl" !="Whitelisted = [];\n_pointsNearby = [];\n_findWhitelisted = nearestObjects [_pos,_whitelist,(_radius + DZE_snapExtraRange)]-[_objec" !=".sqf\"\n\n\n\n\n\nprivate \"_object\";\n\n{\n_object = (_x select 0) nearestObject (_x select 1);\n_object hideObject true;\n_object setVariab" !="\ncall dayz_meleeMagazineCheck;\n{player reveal _x} count (nearestObjects [_position,[\"AllVehicles\",\"WeaponHolder\",\"Land_A_tent\",\"" !="ks.sqf\"\nsetMousePosition [0.5, 0.5];\n\nprivate [\"_exit\",\"_nearestObjects\",\"_rID\",\"_display\",\"_cTarget\",\"_dis\",\"_friendlyTo\",\"_las" !="eenMsg = localize 'str_player_setup_completed';\n_torev4l=nearestObjects [_setPos, Dayz_plants + DayZ_GearedObjects + [\"AllVehicl" !=") then {\n_pPos = [player] call FNC_GetPos;\n_fireplaces = nearestObjects [_pPos, [\"flamable_DZ\",\"Land_Fire\",\"Land_Campfire\"], 8];" !=" \n\n)\nmax 0;\n\nif (_scaleLight < 0.9) then {\n\n_nearFlare = nearestObject [getPosATL (vehicle player),\"RoadFlare\"];\nif (!isNull _ne" !=" call _check}) exitWith { \n_inside = true;\n};\n} forEach (nearestObjects [_unit, [\"Building\"], 50]);\n};\n\n\n_inside\n" !="= _this select 0;\n_ammo = _this select 1;\n\n_projectile = nearestObject [_unit, _ammo];\n_pos = getPosATL _projectile;\n\nif (_ammo " !="\n};\nif (\"workshop\" in _needNear) then {\n_isNear = count (nearestObjects [player, DZE_Workshops, _distance]);\nif(_isNear == 0) th" !="ingPlayer = player;\n_dir = round(random 360);\n_helipad = nearestObjects [player, [\"HeliHCivil\",\"HeliHempty\"], 100];\n\n\nif (count " !="1\",\"land_smd_water_pump\"];\n\n_canFill = call {\n\nif (count nearestObjects [_posATL,_wells,4] > 0) exitwith {[true,false]};\nif (toL" !="d) exitWith {\n_nearWaterHole = [true,_pond];\n};\n} count (nearestObjects [_x, [], 1]);\n\nif (_nearWaterHole select 0) exitWith {};" !="bj select 4;\n_projectile = _obj select 6;\n\n_projectile = nearestObject [_unit,_ammo];\n_endPos = getPosATL _projectile;\n_doWait =" !="_plantOutput select _index;\n_countOut = 1;\n};\n};\n} count nearestObjects [([player] call FNC_getPos), [], 10];\n\nif (count _findNe" !=" !r_player_unconscious && !_onLadder);\n\n_nearByObjects = nearestObjects [player,_objects,_range];\n\nif (count _nearByObjects == 0" !="= \"workshop\") exitwith {\n_distance = 3;\n_isNear = count (nearestObjects [_pos, DZE_Workshops, _distance]);\nif (_isNear == 0) the" !="earestPole) then {_pos} else {_nearestPole};\nif ((count (nearestObjects [_center,_buildables,_distance])) >= DZE_BuildingLimit) " !="_ammo in [\"Dragged\",\"RunOver\"])}) then {\n_vehicleArray = nearestObjects [([vehicle _unit] call fnc_getPos),[\"Air\",\"LandVehicle\"," !="n _rocks) exitWith { _findNearestRock = _x; };\n} foreach nearestObjects [getPosATL player, [], 8];\n\n\nif (!isNull _findNearestRoc" !="modeltoWorld [0,0,0]};\n_holder = objNull;\n\n\n_nearByPile= nearestObjects [_pos, [\"WeaponHolder\",\"WeaponHolderBase\"],2];\n\nif (coun" !="r);\nlocal _uid = getPlayerUID player;\nlocal _nearLight = nearestObject [player,\"LitObject\"];\nlocal _canPickLight = false;\nlocal " !="p = {\nlocal _doors = [];\nif (r_drag_sqf) then {\n_doors = nearestObjects [player, DayZ_DropDrageeObjects, 3]; \nif (count _doors >" !"With {};\nif (!_unconscious) exitWith {};\n\n_dropObjects = nearestObjects [player, DayZ_DropDrageeObjects, 3];\nif (count _dropObje" !"Name) in dayz_trees}) exitWith {\n\n_tree = _x;\n};\n} count nearestObjects [getPosATL player, [], 20];\n\nif (!isNull _tree) then {\n\n" !="ntities [\"Plastic_Pole_EP1_DZ\",15]) select 0;\n_objects = nearestObjects [_target, DZE_maintainClasses, DZE_maintainRange];\n\n_obj" !="E_LockableStorage + [\"DZ_storage_base\"];\n_count = count (nearestObjects [_target,_buildables,_range]);\n\n_colour = \"#ffffff\";\n\nif" !="e;\n_num = ceil (random (player distance _x));\n};\n} count nearestObjects [player, [], 50];\n\nfor \"_i\" from 1 to 10 do {\nif (!_ispo" !="j select 4;\n\n_projectile = _obj select 6;\n\n_projectile = nearestObject [_unit,_ammo];\n_vUp = vectorUp _projectile;\n_endPos = get" !="player;\nif (_vehicle != player) then {\n_servicePoints = (nearestObjects [getPosATL _vehicle,DZE_SP_Classes,DZE_SP_MaxDistance]) " 1 nearObjects !="ratorRunning\",false]))} count (([player] call FNC_getPos) nearObjects [\"Generator_DZ\",30]);\nif (_findNearestGen > 0) then {\ns_pl" !="lders = dayz_currentWeaponHolders - 1;\n} count (_worldPos nearObjects [\"ReammoBox\", 1]);\n\nif (_lootChance > random 1 && {dayz_cu" !="rgets == 0) then {\nprivate \"_objects\";\n\n_objects = _agent nearObjects [\"GrenadeHand\", 300]; \n{\nif (!(_x in _targets)) then {\nif " !="er] call FNC_GetPos;\n_isNear = {inflamed _x} count (_pPos nearObjects _distance);\nif(_isNear == 0) then {\n_abort = true;\n_reason" !="s select 0;\n_sign = _this select 1;\n_near = count (player nearObjects [_class,50]);\n\n[_class,_sign,_near] spawn {\n_class = _this" !="with {\n_distance = 3;\n_isNear = {inflamed _x} count (_pos nearObjects _distance);\nif (_isNear == 0) then {\n_abort = true;\n_reaso" !=" (_nearWaterHole select 0) exitWith {};\n} forEach (player nearObjects [\"waterHoleProxy\",50]);\n\n_nearWaterHole" !="yer] call FNC_GetPos;\n_isNear = {inflamed _x} count (_pos nearObjects 3);\nif (_isNear == 0) exitWith {dayz_actionInProgress = fa" !="unt _zeds;\n\n\ndayz_currentWeaponHolders = count (_position nearObjects [\"ReammoBox\",_radius]);\n\n\nif (DZE_Bloodsuckers) then {\nloc" 1 onMapSingleClick @@ -77,7 +77,7 @@ 1 setPosASL !="_unit setPosAsl [(_position select 0), (_position select 1), (LHA_height+1)];" !="_flame setPosASL [_pos select 0,_pos select 1,(_pos select 2)+0.2];" !="_fire setPosASL _location;" !"_objectHelper setPosASL _position;\n} else {" !"_b0x1337 setPosASL (getPosASL player);\n} else {" !"_obj setPosASL [_center select 0, _a, _b];" !"_objectSnapGizmo setPosASL " !"_para setposasl [\n" !"_thingy setPosASL (ATLToASL _pos);\n} else {" !="> \"fixWaterPos\");\nif (_fixWaterSpawn == 1) then {\n_vehicle setPosASL (_pos);\n} else {\n_vehicle setPos (_pos);\n}; \n} else {\n_ve" 1 setTerrainGrid 1 setUnitRecoilCoefficient -1 setVehicle !"if(_status) then {\n_vehicle setVehicleLock \"LOCKED\";\n} else {\n_vehicle setVehicleLock \"UNLOCKED\";\n};" +1 setVehicle !"if(_status) then {\n_vehicle setVehicleLock \"LOCKED\";\n} else {\n_vehicle setVehicleLock \"UNLOCKED\";\n};" !="stentMoney),(_wealth - _amount),true];};\n\nvkc_cursorTarget setVehicleLock \"LOCKED\";\nplayer playActionNow \"Medic\";\n\n_position = [" 1 setViewDistance 1 sideLogic !"publicVariable \"BIS_MPF_logic\";" 1 switchCamera !"\"switchCamera\", " !"rswitchCamera" !"player switchCamera _currentCamera;\nif (_currentWpn !=" !"< 150) && random 1 > 0.5) then {\n_killer switchcamera"