small change

This commit is contained in:
Zac Surplice
2013-11-27 15:42:38 +11:00
parent a46cec0036
commit 6a58370670
50 changed files with 201 additions and 201 deletions

View File

@@ -8,7 +8,7 @@ private ["_weaponName","_action","_turret","_weapons","_assignedRole","_action1"
disableSerialization;
if (TradeInprogress) exitWith {}; // Do not allow if any script is running.
if (DZE_ActionInProgress) exitWith {}; // Do not allow if any script is running.
_menClose = cursorTarget;
_hasPatient = alive _menClose;

View File

@@ -6,7 +6,7 @@ scriptName "Functions\misc\fn_selfActions.sqf";
************************************************************/
private ["_isWreckBuilding","_temp_keys","_magazinesPlayer","_isPZombie","_vehicle","_inVehicle","_hasFuelE","_hasRawMeat","_hasKnife","_hasToolbox","_onLadder","_nearLight","_canPickLight","_canDo","_text","_isHarvested","_isVehicle","_isVehicletype","_isMan","_traderType","_ownerID","_isAnimal","_isDog","_isZombie","_isDestructable","_isTent","_isFuel","_isAlive","_Unlock","_lock","_buy","_dogHandle","_lieDown","_warn","_hastinitem","_allowedDistance","_menu","_menu1","_humanity_logic","_low_high","_cancel","_metals_trader","_traderMenu","_isWreck","_isRemovable","_isDisallowRepair","_rawmeat","_humanity","_speed","_dog","_hasbottleitem","_isAir","_isShip","_playersNear","_findNearestGens","_findNearestGen","_IsNearRunningGen","_cursorTarget","_isnewstorage","_itemsPlayer","_ownerKeyId","_typeOfCursorTarget","_hasKey","_oldOwner","_combi","_key_colors","_player_deleteBuild","_player_flipveh","_player_lockUnlock_crtl","_player_butcher","_player_studybody","_player_cook","_player_boil","_hasFuelBarrelE","_hasHotwireKit","_player_SurrenderedGear","_isSurrendered","_isModular","_ownerKeyName","_temp_keys_names"];
if (TradeInprogress) exitWith {}; // Do not allow if any script is running.
if (DZE_ActionInProgress) exitWith {}; // Do not allow if any script is running.
_vehicle = vehicle player;
_isPZombie = player isKindOf "PZombie_VB";

View File

@@ -5,8 +5,8 @@
*/
private ["_objectID","_objectUID","_obj","_ownerID","_dir","_pos","_holder","_weapons","_magazines","_backpacks","_alreadyPacking","_lockedClass","_text","_playerNear"];
if(TradeInprogress) exitWith { cutText [(localize "str_epoch_player_10") , "PLAIN DOWN"]; };
TradeInprogress = true;
if(DZE_ActionInProgress) exitWith { cutText [(localize "str_epoch_player_10") , "PLAIN DOWN"]; };
DZE_ActionInProgress = true;
player removeAction s_player_lockvault;
s_player_lockvault = 1;
@@ -18,7 +18,7 @@ _lockedClass = getText (configFile >> "CfgVehicles" >> _objType >> "lockedClass"
_text = getText (configFile >> "CfgVehicles" >> _objType >> "displayName");
// Silently exit if object no longer exists
if(isNull _obj) exitWith { TradeInprogress = false; };
if(isNull _obj) exitWith { DZE_ActionInProgress = false; };
[1,1] call dayz_HungerThirst;
player playActionNow "Medic";
sleep 1;
@@ -26,16 +26,16 @@ sleep 1;
sleep 5;
_playerNear = _obj call dze_isnearest_player;
if(_playerNear) exitWith { TradeInprogress = false; cutText [(localize "str_epoch_player_11") , "PLAIN DOWN"]; };
if(_playerNear) exitWith { DZE_ActionInProgress = false; cutText [(localize "str_epoch_player_11") , "PLAIN DOWN"]; };
_ownerID = _obj getVariable["CharacterID","0"];
_objectID = _obj getVariable["ObjectID","0"];
_objectUID = _obj getVariable["ObjectUID","0"];
if((_ownerID != dayz_combination) and (_ownerID != dayz_playerUID)) exitWith {TradeInprogress = false; s_player_lockvault = -1; cutText [format[(localize "str_epoch_player_115"),_text], "PLAIN DOWN"]; };
if((_ownerID != dayz_combination) and (_ownerID != dayz_playerUID)) exitWith {DZE_ActionInProgress = false; s_player_lockvault = -1; cutText [format[(localize "str_epoch_player_115"),_text], "PLAIN DOWN"]; };
_alreadyPacking = _obj getVariable["packing",0];
if (_alreadyPacking == 1) exitWith {TradeInprogress = false; s_player_lockvault = -1; cutText [format[(localize "str_epoch_player_116"),_text], "PLAIN DOWN"]};
if (_alreadyPacking == 1) exitWith {DZE_ActionInProgress = false; s_player_lockvault = -1; cutText [format[(localize "str_epoch_player_116"),_text], "PLAIN DOWN"]};
_obj setVariable["packing",1];
_dir = direction _obj;
@@ -79,4 +79,4 @@ if(!isNull _obj) then {
cutText [format[(localize "str_epoch_player_117"),_text], "PLAIN DOWN"];
};
s_player_lockvault = -1;
TradeInprogress = false;
DZE_ActionInProgress = false;

View File

@@ -3,8 +3,8 @@
*/
private ["_activatingPlayer","_objectID","_objectUID","_obj","_ownerID","_dir","_pos","_object","_holder","_weapons","_magazines","_backpacks","_objWpnTypes","_objWpnQty","_countr","_alreadyPacking","_dis","_sfx","_classname","_location"];
if(TradeInprogress) exitWith { cutText [(localize "str_epoch_player_13") , "PLAIN DOWN"]; };
TradeInprogress = true;
if(DZE_ActionInProgress) exitWith { cutText [(localize "str_epoch_player_13") , "PLAIN DOWN"]; };
DZE_ActionInProgress = true;
player removeAction s_player_packtent;
s_player_packtent = 1;
@@ -18,13 +18,13 @@ _objectUID = _obj getVariable["ObjectUID","0"];
[1,1] call dayz_HungerThirst;
player playActionNow "Medic";
if(_objectID == "0" && _objectUID == "0") exitWith {TradeInprogress = false; s_player_packtent = -1; cutText [(localize "str_epoch_player_14"), "PLAIN DOWN"];};
if(_objectID == "0" && _objectUID == "0") exitWith {DZE_ActionInProgress = false; s_player_packtent = -1; cutText [(localize "str_epoch_player_14"), "PLAIN DOWN"];};
if(_ownerID != dayz_characterID) exitWith {TradeInprogress = false; s_player_packtent = -1; cutText [localize "str_fail_tent_pack", "PLAIN DOWN"];};
if(_ownerID != dayz_characterID) exitWith {DZE_ActionInProgress = false; s_player_packtent = -1; cutText [localize "str_fail_tent_pack", "PLAIN DOWN"];};
_alreadyPacking = _obj getVariable["packing",0];
if (_alreadyPacking == 1) exitWith {TradeInprogress = false; s_player_packtent = -1; cutText [format[(localize "str_player_beingpacked")] , "PLAIN DOWN"]};
if (_alreadyPacking == 1) exitWith {DZE_ActionInProgress = false; s_player_packtent = -1; cutText [format[(localize "str_player_beingpacked")] , "PLAIN DOWN"]};
_obj setVariable["packing",1];
@@ -102,4 +102,4 @@ if(!isNull _obj and alive _obj) then {
};
s_player_packtent = -1;
TradeInprogress = false;
DZE_ActionInProgress = false;

View File

@@ -3,8 +3,8 @@
*/
private ["_activatingPlayer","_obj","_ownerID","_objectID","_objectUID","_alreadyPacking","_location1","_location2","_dir","_pos","_bag","_holder","_weapons","_magazines","_backpacks","_objWpnTypes","_objWpnQty","_countr","_packedClass","_text","_playerNear"];
if(TradeInprogress) exitWith { cutText [(localize "str_epoch_player_15") , "PLAIN DOWN"]; };
TradeInprogress = true;
if(DZE_ActionInProgress) exitWith { cutText [(localize "str_epoch_player_15") , "PLAIN DOWN"]; };
DZE_ActionInProgress = true;
_activatingPlayer = getPlayerUID player;
@@ -14,11 +14,11 @@ _packedClass = getText (configFile >> "CfgVehicles" >> (typeOf _obj) >> "packedC
_text = getText (configFile >> "CfgVehicles" >> (typeOf _obj) >> "displayName");
// Silently exit if object no longer exists
if(isNull _obj or !(alive _obj)) exitWith { TradeInprogress = false; };
if(isNull _obj or !(alive _obj)) exitWith { DZE_ActionInProgress = false; };
_playerNear = _obj call dze_isnearest_player;
if(_playerNear) exitWith { TradeInprogress = false; cutText [(localize "str_epoch_player_16") , "PLAIN DOWN"]; };
if(_playerNear) exitWith { DZE_ActionInProgress = false; cutText [(localize "str_epoch_player_16") , "PLAIN DOWN"]; };
_ownerID = _obj getVariable["CharacterID","0"];
_objectID = _obj getVariable["ObjectID","0"];
@@ -27,13 +27,13 @@ _objectUID = _obj getVariable["ObjectUID","0"];
player removeAction s_player_packvault;
s_player_packvault = 1;
if(_objectID == "0" && _objectUID == "0") exitWith {TradeInprogress = false; s_player_packvault = -1; cutText [format[(localize "str_epoch_player_118"),_text], "PLAIN DOWN"];};
if(_objectID == "0" && _objectUID == "0") exitWith {DZE_ActionInProgress = false; s_player_packvault = -1; cutText [format[(localize "str_epoch_player_118"),_text], "PLAIN DOWN"];};
if((_ownerID != dayz_combination) and (_ownerID != dayz_playerUID)) exitWith { TradeInprogress = false; s_player_packvault = -1; cutText [format[(localize "str_epoch_player_119"),_text], "PLAIN DOWN"];};
if((_ownerID != dayz_combination) and (_ownerID != dayz_playerUID)) exitWith { DZE_ActionInProgress = false; s_player_packvault = -1; cutText [format[(localize "str_epoch_player_119"),_text], "PLAIN DOWN"];};
_alreadyPacking = _obj getVariable["packing",0];
if (_alreadyPacking == 1) exitWith {TradeInprogress = false; s_player_packvault = -1; cutText [format[(localize "str_epoch_player_120"),_text] , "PLAIN DOWN"]};
if (_alreadyPacking == 1) exitWith {DZE_ActionInProgress = false; s_player_packvault = -1; cutText [format[(localize "str_epoch_player_120"),_text] , "PLAIN DOWN"]};
_obj setVariable["packing",1];
cutText [format[(localize "str_epoch_player_121"),_text], "PLAIN DOWN"];
@@ -111,4 +111,4 @@ if(!isNull _obj and alive _obj) then {
player action ["Gear", _holder];
};
s_player_packvault = -1;
TradeInprogress = false;
DZE_ActionInProgress = false;

View File

@@ -5,8 +5,8 @@
*/
private ["_objectID","_objectUID","_obj","_ownerID","_dir","_pos","_holder","_weapons","_magazines","_backpacks","_objWpnTypes","_objWpnQty","_countr","_alreadyPacking","_playerNear","_playerID","_claimedBy","_unlockedClass","_text","_nul","_objType"];
if(TradeInprogress) exitWith { cutText [(localize "str_epoch_player_21") , "PLAIN DOWN"]; };
TradeInprogress = true;
if(DZE_ActionInProgress) exitWith { cutText [(localize "str_epoch_player_21") , "PLAIN DOWN"]; };
DZE_ActionInProgress = true;
{player removeAction _x} forEach s_player_combi;s_player_combi = [];
s_player_unlockvault = 1;
@@ -15,10 +15,10 @@ _obj = _this;
_objType = typeOf _obj;
_playerNear = _obj call dze_isnearest_player;
if(_playerNear) exitWith { TradeInprogress = false; cutText [(localize "str_epoch_player_20") , "PLAIN DOWN"]; };
if(_playerNear) exitWith { DZE_ActionInProgress = false; cutText [(localize "str_epoch_player_20") , "PLAIN DOWN"]; };
// Silently exit if object no longer exists or alive
if(isNull _obj or !(alive _obj)) exitWith { TradeInprogress = false; };
if(isNull _obj or !(alive _obj)) exitWith { DZE_ActionInProgress = false; };
_unlockedClass = getText (configFile >> "CfgVehicles" >> _objType >> "unlockedClass");
_text = getText (configFile >> "CfgVehicles" >> _objType >> "displayName");
@@ -27,7 +27,7 @@ _alreadyPacking = _obj getVariable["packing",0];
_claimedBy = _obj getVariable["claimed","0"];
_ownerID = _obj getVariable["CharacterID","0"];
if (_alreadyPacking == 1) exitWith {TradeInprogress = false; cutText [format[(localize "str_epoch_player_124"),_text], "PLAIN DOWN"]};
if (_alreadyPacking == 1) exitWith {DZE_ActionInProgress = false; cutText [format[(localize "str_epoch_player_124"),_text], "PLAIN DOWN"]};
// Promt user for password if _ownerID != dayz_playerUID
if ((_ownerID == dayz_combination) or (_ownerID == dayz_playerUID)) then {
@@ -112,7 +112,7 @@ if ((_ownerID == dayz_combination) or (_ownerID == dayz_playerUID)) then {
cutText [format[(localize "str_epoch_player_125"),_text], "PLAIN DOWN"];
};
} else {
TradeInprogress = false;
DZE_ActionInProgress = false;
cutText [format[(localize "str_player_beinglooted"),_text] , "PLAIN DOWN"];
};
} else {
@@ -125,4 +125,4 @@ if ((_ownerID == dayz_combination) or (_ownerID == dayz_playerUID)) then {
cutText [format[(localize "str_epoch_player_126"),_text], "PLAIN DOWN"];
};
s_player_unlockvault = -1;
TradeInprogress = false;
DZE_ActionInProgress = false;

View File

@@ -4,8 +4,8 @@
*/
private ["_proceed","_itemIn","_countIn","_missing","_missingQty","_qty","_removed","_tobe_removed_total","_textMissing","_num_removed","_removed_total","_temp_removed_array","_countr","_objectID","_objectUID","_location","_dir","_objectCharacterID","_weapons","_magazines","_backpacks","_classname","_object","_holder","_objWpnTypes","_objWpnQty","_newclassname","_requirements","_upgrade","_vehicle","_findNearestVehicles","_findNearestVehicle","_IsNearVehicle"];
if(TradeInprogress) exitWith { cutText [(localize "STR_EPOCH_PLAYER_52") , "PLAIN DOWN"]; };
TradeInprogress = true;
if(DZE_ActionInProgress) exitWith { cutText [(localize "STR_EPOCH_PLAYER_52") , "PLAIN DOWN"]; };
DZE_ActionInProgress = true;
// look for nearest vehicle
_findNearestVehicles = nearestObjects [player, ["LandVehicle"], 10];
@@ -166,4 +166,4 @@ if (_IsNearVehicle >= 1) then {
cutText [(localize "STR_EPOCH_PLAYER_27"), "PLAIN DOWN"];
};
TradeInprogress = false;
DZE_ActionInProgress = false;