This commit is contained in:
icomrade
2016-08-15 21:35:13 -04:00
31 changed files with 323 additions and 2236 deletions

View File

@@ -29,7 +29,8 @@ class MilitarySpecial : Military
lootChance = 0.4;
lootGroup = MilitarySpecial;
};
class MilitaryIndustrial: Military {
class MilitaryIndustrial: Military
{
zombieChance = 0.3;
maxRoaming = 6;
zombieClass[] =
@@ -41,13 +42,13 @@ class MilitaryIndustrial: Military {
"z_worker2",
"z_worker3"
};
lootChance = 0.4;
lootChance = 0.5;
lootGroup = MilitaryIndustrial;
};
class Land_a_stationhouse : Military
{
zedPos[] = {{-0.892578,-5.7168,-9.47058},{1.5127,1.96484,-9.47058},{18.9063,-4.06738,-9.47058},{-2.69922,-7.57422,-9.46057},{-1.35645,-8.3623,-4.6489},{-3.24219,-6.61914,-4.6489},{-1.70801,-7.85449,-0.0437927},{-3.39453,-7.88281,-0.0437927},{-1.37891,-5.79102,4.41141},{-1.39648,-7.79883,4.41141}};
lootChance = 0.3;
lootChance = 0.5;
lootPos[] = {
//{-2.7,-7.57,-9.46},{-0.89,-5.72,-9.47},{-3.24,-6.62,-4.65},{-1.36,-8.36,-4.65},{-1.71,-7.85,-0.04},{-3.39,-7.88,-0.04},{-1.4,-7.8,4.41},{-1.38,-5.79,4.41},{1.51,1.96,-9.47},{18.91,-4.07,-9.47},{-14.4,3.29,-0.51},{1.33,0.89,-0.51},{-2.37,-8.4,8.49},{12.44,2.54,-9.47},{-14.83,-7.58,-0.51},{-1.8,8.87,-0.51},{6.83,0.89,-0.51},{3.65,-6.54,-4.51},{16.29,-6.57,-4.51},{18.39,2.37,-4.51},{9.28,-1.25,-4.51},{-2.08,-4.74,8.49},
{15.436,2.85498,-9.47058},{17.9861,-6.52832,-9.47058},{1.22583,2.24463,-9.47058},{-3.9126,-7.29834,-9.47058},{-2.28271,-6.21094,-4.6489},{-1.604,-8.68018,-0.043786},{-1.104,-5.60938,4.41139},{-3.55811,-8.56787,4.41139},{-2.99219,-8.27148,8.49209}
@@ -489,7 +490,7 @@ class HMMWVWreck: Military
lootPos[] = {};
};
class Land_Mil_Guardhouse : Military //MOVED FROM RESIDENTIAL
class Land_Mil_Guardhouse: Military //MOVED FROM RESIDENTIAL
{
zombieClass[] =
{
@@ -497,6 +498,7 @@ class Land_Mil_Guardhouse : Military //MOVED FROM RESIDENTIAL
"z_soldier",
"z_policeman"
};
lootChance = 0.5;
maxRoaming = 3;
zedPos[] = {{-2.44727,0.250977,-1.70563},{-2.44873,3.00293,-1.70285}};
lootPos[] = {

View File

@@ -1,27 +1,30 @@
Hangar[] =
{
{Loot_GROUP, 10, MilitarySpecial},
{Loot_GROUP, 8, MilitarySpecial},
//Tools
{Loot_WEAPON, 2, ItemEtool},
{Loot_WEAPON, 4, ItemEtool},
//Items
{Loot_MAGAZINE, 2, PartVRotor},
{Loot_MAGAZINE, 2, ItemSandbag},
{Loot_MAGAZINE, 2, ItemWire},
{Loot_MAGAZINE, 2, ItemTankTrap},
{Loot_MAGAZINE, 1, PartEngine},
{Loot_MAGAZINE, 4, PartGeneric},
{Loot_MAGAZINE, 3, PartGlass},
{Loot_MAGAZINE, 3, ItemSandbag},
{Loot_MAGAZINE, 3, ItemWire},
{Loot_MAGAZINE, 3, ItemTankTrap},
//Groups
{Loot_GROUP, 20, Trash},
{Loot_GROUP, 20, Consumable},
{Loot_GROUP, 10, Generic},
{Loot_GROUP, 5, AttachmentsGeneric}
{Loot_PILE, 6, Trash, 1, 2},
{Loot_PILE, 3, Consumable, 1, 2},
{Loot_GROUP, 6, Generic},
{Loot_GROUP, 3, AttachmentsGeneric}
};
HangarSmall[] =
{
{Loot_TOOL, 2, Binocular},
{Loot_WEAPON, 2, NVGoggles},
{Loot_GROUP, 10, pistols},
{Loot_GROUP, 8, pistols},
{Loot_TOOL, 2, Binocular_Vector},
{Loot_TOOL, 3, ItemKnife},
{Loot_TOOL, 1.3, ItemGPS},
@@ -31,12 +34,12 @@ HangarSmall[] =
{Loot_MAGAZINE, 0.5, PipeBomb},
{Loot_MAGAZINE, 0.5, MAAWS_HEAT},
{Loot_MAGAZINE, 2, 100Rnd_762x54_PK},
{Loot_GROUP, 15, AmmoMilitaryLow},
{Loot_GROUP, 10, AmmoMilitaryHigh},
{Loot_GROUP, 8, AmmoMilitaryLow},
{Loot_GROUP, 8, AmmoMilitaryHigh},
{Loot_GROUP, 8, AttachmentsEast},
{Loot_GROUP, 6, AttachmentsWest},
{Loot_GROUP, 10, MedicalLow},
{Loot_GROUP, 10, Trash},
{Loot_GROUP, 10, Consumable},
{Loot_GROUP, 8, MedicalLow},
{Loot_GROUP, 8, Trash},
{Loot_GROUP, 8, Consumable},
{Loot_GROUP, 8, GenericSmall}
};
};

View File

@@ -3,7 +3,6 @@ Industrial[] =
//Tools
{Loot_WEAPON, 3, ItemKnife},
{Loot_WEAPON, 6, ItemToolbox},
// {Loot_WEAPON, 2, ItemFlashlight},
// {Loot_WEAPON, 8, ItemCrowbar},
{Loot_VEHICLE, 8, WeaponHolder_ItemCrowbar},
// {Loot_WEAPON, 5, ItemHatchet},
@@ -16,10 +15,10 @@ Industrial[] =
{Loot_WEAPON, 1, ItemKeyKit},
//Items
{Loot_MAGAZINE, 6, ItemSandbag},
// {Loot_MAGAZINE, 6, ItemSandbag},
{Loot_MAGAZINE, 4, ItemJerryCan},
{Loot_MAGAZINE, 1, ItemWire},
{Loot_MAGAZINE, 4, ItemTankTrap},
// {Loot_MAGAZINE, 1, ItemWire},
// {Loot_MAGAZINE, 4, ItemTankTrap},
{Loot_MAGAZINE, 1, equip_brick},
{Loot_MAGAZINE, 3, equip_duct_tape},
{Loot_MAGAZINE, 2, equip_hose},
@@ -29,7 +28,7 @@ Industrial[] =
{Loot_MAGAZINE, 2, equip_metal_sheet},
{Loot_MAGAZINE, 2, equip_1inch_metal_pipe},
{Loot_MAGAZINE, 2, equip_2inch_metal_pipe},
{Loot_MAGAZINE, 12, ItemPlank},
{Loot_MAGAZINE, 8, ItemPlank},
{Loot_MAGAZINE, 2, MortarBucket},
{Loot_MAGAZINE, 3, CinderBlocks},
{Loot_MAGAZINE, 3, ItemFuelBarrelEmpty},
@@ -38,10 +37,9 @@ Industrial[] =
//Other
{Loot_GROUP, 15, Parts},
// {Loot_GROUP, 7, Military},
{Loot_PILE, 10, Trash, 1, 3},
{Loot_PILE, 4, Consumable, 1, 2},
{Loot_GROUP, 8, Generic}
{Loot_PILE, 3, Consumable, 1, 2},
{Loot_GROUP, 5, Generic}
};
IndustrialSmall[] =
@@ -51,6 +49,6 @@ IndustrialSmall[] =
{Loot_MAGAZINE, 2, equip_duct_tape},
{Loot_MAGAZINE, 6, equip_nails},
{Loot_GROUP, 10, Trash},
{Loot_GROUP, 4, Consumable},
{Loot_GROUP, 8, GenericSmall}
{Loot_GROUP, 3, Consumable},
{Loot_GROUP, 5, GenericSmall}
};

View File

@@ -39,15 +39,15 @@ Military[] =
//Other
{Loot_MAGAZINE, 5, FoodMRE},
{Loot_MAGAZINE, 4, ItemSandbag},
// {Loot_MAGAZINE, 4, ItemSandbag},
{Loot_PILE, 15, AmmoMilitaryLow, 1, 3},
{Loot_GROUP, 4, AmmoMilitaryHigh},
{Loot_GROUP, 4, AttachmentsGeneric},
{Loot_GROUP, 8, AttachmentsEast},
{Loot_PILE, 10, MedicalLow, 1, 2},
{Loot_PILE, 15, Trash, 1, 2},
{Loot_PILE, 10, Consumable, 1, 2},
{Loot_GROUP, 10, Generic}
{Loot_PILE, 10, Consumable, 1, 2}
// {Loot_GROUP, 10, Generic}
};
MilitarySmall[] =
@@ -58,15 +58,15 @@ MilitarySmall[] =
{Loot_TOOL, 3, ItemMap},
{Loot_TOOL, 3, ItemKnife},
{Loot_GROUP, 2, militaryclothes},
{Loot_GROUP, 1, specialclothes},
{Loot_GROUP, 2, specialclothes},
{Loot_GROUP, 15, AmmoMilitaryLow},
{Loot_GROUP, 4, AmmoMilitaryHigh},
{Loot_GROUP, 4, AttachmentsGeneric},
{Loot_GROUP, 8, AttachmentsEast},
{Loot_GROUP, 10, MedicalLow},
{Loot_GROUP, 15, Trash},
{Loot_GROUP, 10, Consumable},
{Loot_GROUP, 10, GenericSmall}
{Loot_GROUP, 10, Consumable}
// {Loot_GROUP, 10, GenericSmall}
};
MilitarySpecial[] =
@@ -107,7 +107,7 @@ MilitarySpecial[] =
//Other
{Loot_MAGAZINE, 3, FoodMRE},
{Loot_MAGAZINE, 2, ItemSandbag},
// {Loot_MAGAZINE, 2, ItemSandbag},
{Loot_MAGAZINE, 0.5, PipeBomb},
{Loot_MAGAZINE, 0.5, MAAWS_HEAT},
{Loot_MAGAZINE, 2, 100Rnd_762x54_PK},
@@ -118,8 +118,8 @@ MilitarySpecial[] =
{Loot_GROUP, 6, AttachmentsWest},
{Loot_PILE, 10, MedicalLow, 1, 2},
{Loot_PILE, 10, Trash, 1, 2},
{Loot_PILE, 10, Consumable, 1, 2},
{Loot_GROUP, 8, Generic}
{Loot_PILE, 10, Consumable, 1, 2}
// {Loot_GROUP, 8, Generic}
};
MilitarySpecialSmall[] =
@@ -143,8 +143,8 @@ MilitarySpecialSmall[] =
{Loot_GROUP, 6, AttachmentsWest},
{Loot_GROUP, 10, MedicalLow},
{Loot_GROUP, 10, Trash},
{Loot_GROUP, 10, Consumable},
{Loot_GROUP, 8, GenericSmall}
{Loot_GROUP, 10, Consumable}
// {Loot_GROUP, 8, GenericSmall}
};
MilitaryIndustrial[] = {//DZE ADDED
@@ -153,9 +153,15 @@ MilitaryIndustrial[] = {//DZE ADDED
{Loot_MAGAZINE, 3, ItemFuelBarrelEmpty},
{Loot_MAGAZINE, 2, ItemGenerator},
{Loot_MAGAZINE, 2, fuel_pump_kit},
{Loot_GROUP, 15, Military}
{Loot_MAGAZINE, 3, ItemWire},
{Loot_MAGAZINE, 3, ItemTankTrap},
{Loot_MAGAZINE, 6, ItemSandbag},
{Loot_MAGAZINE, 1, PartEngine},
{Loot_GROUP, 15, Military},
{Loot_GROUP, 4, Generic}
};
MilitaryIndustrialSmall[] = {
{Loot_GROUP, 15, MilitarySmall}
{Loot_GROUP, 15, MilitarySmall},
{Loot_GROUP, 8, GenericSmall}
};

View File

@@ -10,6 +10,11 @@ Generic[] =
//DZE
{Loot_MAGAZINE, 1, 5Rnd_17HMR},
{Loot_MAGAZINE, 2, 10Rnd_303British},
{Loot_MAGAZINE, 2, 15Rnd_W1866_Slug},
{Loot_MAGAZINE, 2, 5Rnd_762x54_Mosin},
{Loot_MAGAZINE, 2, 8Rnd_9x18_Makarov},
{Loot_MAGAZINE, 2, 7Rnd_45ACP_1911},
{Loot_MAGAZINE, 2, 6Rnd_45ACP},
// {Loot_MAGAZINE, 1, ItemBookBible},
@@ -40,8 +45,13 @@ GenericSmall[] =
{Loot_MAGAZINE, 1, HandChemRed},
{Loot_MAGAZINE, 1, 5Rnd_17HMR},
{Loot_MAGAZINE, 2, 10Rnd_303British},
{Loot_MAGAZINE, 2, 15Rnd_W1866_Slug},
{Loot_MAGAZINE, 1, 5Rnd_762x54_Mosin},
{Loot_MAGAZINE, 2, 8Rnd_9x18_Makarov},
{Loot_MAGAZINE, 2, 7Rnd_45ACP_1911},
{Loot_MAGAZINE, 1, 6Rnd_45ACP},
{Loot_MAGAZINE, 1, equip_string},
{Loot_MAGAZINE, 1, equip_duct_tape},
{Loot_MAGAZINE, 1, equip_rope},
{Loot_MAGAZINE, 1, equip_nails}
};
};

View File

@@ -1,10 +1,8 @@
ZombiePolice[] =
{
{Loot_GROUP, 2, Consumable},
{Loot_MAGAZINE, 2, 7Rnd_45ACP_1911},
{Loot_GROUP, 3, AmmoCivilian},
{Loot_MAGAZINE, 2, ItemDocument},
{Loot_MAGAZINE, 3, 6Rnd_45ACP},
{Loot_MAGAZINE, 1, 8Rnd_12Gauge_Buck},
{Loot_MAGAZINE, 1, ItemHotwireKit},
{Loot_MAGAZINE, 2, ItemComboLock},
{Loot_MAGAZINE, 3, HandRoadFlare}
@@ -14,4 +12,4 @@ ZombiePoliceViral[] =
{
{Loot_GROUP, 10, ZombiePolice},
{Loot_MAGAZINE, 1, ItemAntibiotic1}
};
};

View File

@@ -3,13 +3,13 @@ class G36K_Camo_DZ : G36C
model = "z\addons\dayz_communityweapons\g36\g36k_camo.p3d";
picture = "\z\addons\dayz_communityweapons\g36\data\w_g36k_camo_ca.paa";
displayName = $STR_DZ_WPN_G36K_CAMO_NAME;
/*
magazines[] =
{
30Rnd_556x45_G36,
30Rnd_556x45_G36SD
};
*/
//G36 Optic
optics = true;
opticsDisablePeripherialVision = true;
@@ -84,13 +84,13 @@ class G36K_Camo_SD_DZ : G36_C_SD_eotech
model = "z\addons\dayz_communityweapons\g36\g36k_camo_sd.p3d";
picture = "\z\addons\dayz_communityweapons\g36\data\w_g36k_camo_sd_ca.paa";
displayName = $STR_DZ_WPN_G36K_CAMO_SD_NAME;
/*
magazines[] =
{
30Rnd_556x45_G36SD,
30Rnd_556x45_G36
};
*/
//G36 Optic
optics = true;
opticsDisablePeripherialVision = true;

View File

@@ -41,13 +41,13 @@ class G36C_DZ : G36C
model = "z\addons\dayz_communityweapons\g36c\g36c.p3d";
picture = "\z\addons\dayz_communityweapons\g36c\data\w_g36c_ca.paa";
displayName = $STR_DZ_WPN_G36C_NAME;
/*
magazines[] =
{
30Rnd_556x45_G36,
30Rnd_556x45_G36SD
};
*/
class Attachments
{
Attachment_CCO = "G36C_CCO_DZ";
@@ -61,13 +61,13 @@ class G36C_SD_DZ : G36_C_SD_eotech
model = "z\addons\dayz_communityweapons\g36c\g36c_sd.p3d";
picture = "\z\addons\dayz_communityweapons\g36c\data\w_g36c_sd_ca.paa";
displayName = $STR_DZ_WPN_G36C_SD_NAME;
/*
magazines[] =
{
30Rnd_556x45_G36SD,
30Rnd_556x45_G36
};
*/
class Attachments
{
Attachment_CCO = "G36C_CCO_SD_DZ";

View File

@@ -1,8 +1,10 @@
class L85_Holo_DZ : BAF_L85A2_RIS_Holo
{
/*
magazines[] =
{
30Rnd_556x45_Stanag,
30Rnd_556x45_StanagSD
};
*/
};

View File

@@ -1,11 +1,13 @@
//no attachments on either of the M16A2s.
class M16A2_DZ : M16A2
{
/*
magazines[] =
{
30Rnd_556x45_Stanag,
30Rnd_556x45_StanagSD
};
*/
class Attachments
{
Attachment_M203 = "M16A2_GL_DZ";
@@ -14,11 +16,13 @@ class M16A2_DZ : M16A2
class M16A2_GL_DZ : M16A2GL
{
/*
magazines[] =
{
30Rnd_556x45_Stanag,
30Rnd_556x45_StanagSD
};
*/
class ItemActions
{
class RemoveGL

View File

@@ -53,13 +53,13 @@ class M16A4_DZ : M16A2
model = "z\addons\dayz_communityweapons\m16a4\m16a4.p3d";
picture = "\z\addons\dayz_communityweapons\m16a4\data\w_m16a4_ca.paa";
displayName = $STR_DZ_WPN_M16A4;
/*
magazines[] =
{
30Rnd_556x45_Stanag,
30Rnd_556x45_StanagSD
};
*/
class Attachments
{
Attachment_CCO = "M16A4_CCO_DZ";

View File

@@ -59,13 +59,13 @@ class M4A1_DZ : M4A1
displayName = $STR_DZ_WPN_M4A1_NAME;
handAnim[]={"OFP2_ManSkeleton","\Ca\weapons_E\SCAR\Data\Anim\SCAR.rtm"};
/*
magazines[] =
{
30Rnd_556x45_Stanag,
30Rnd_556x45_StanagSD
};
*/
class Attachments
{
Attachment_CCO = "M4A1_CCO_DZ";
@@ -117,13 +117,13 @@ class M4A1_SD_DZ : M4A1_AIM_SD_camo
displayName = $STR_DZ_WPN_M4A1_SD_NAME;
handAnim[]={"OFP2_ManSkeleton","\Ca\weapons_E\SCAR\Data\Anim\SCAR.rtm"};
/*
magazines[] =
{
30Rnd_556x45_StanagSD,
30Rnd_556x45_Stanag
};
*/
class Attachments
{
Attachment_CCO = "M4A1_CCO_SD_DZ";

View File

@@ -42,7 +42,7 @@ class PlotManagement
x = 0.41 * safezoneW + safezoneX;
y = 0.22 * safezoneH + safezoneY;
w = 0.08 * safezoneW;
onButtonClick = "[""preview""] call MaintainPlot;";
onButtonClick = "'preview' call MaintainPlot;";
};
class RscShortcutButton_7011: ZSC_RscButtonMenuBlue
@@ -52,7 +52,7 @@ class PlotManagement
x = 0.51 * safezoneW + safezoneX;
y = 0.22 * safezoneH + safezoneY;
w = 0.08 * safezoneW;
onButtonClick = "[""maintain""] call MaintainPlot;";
onButtonClick = "'maintain' call MaintainPlot;";
};
class RscText_7012: ZSC_RscTextT
{

View File

@@ -1,130 +0,0 @@
//Code developed by Axe Cop - Massiv improvments and performance tunes by Skaronator
private ["_missing","_missingQty","_proceed","_itemIn","_countIn","_qty","_num_removed","_uniqueID","_removed","_removed_total","_tobe_removed_total","_obj","_objectID","_objectUID","_classname","_location","_dir","_objectCharacterID","_object","_temp_removed_array","_textMissing","_target","_objectClasses","_range","_objects","_requirements","_count","_cost","_itemText","_option"];
if (DZE_ActionInProgress) exitWith {localize "STR_EPOCH_ACTIONS_2" call dayz_rollingMessages;};
DZE_ActionInProgress = true;
player removeAction s_player_maintain_area;
s_player_maintain_area = 1;
player removeAction s_player_maintain_area_preview;
s_player_maintain_area_preview = 1;
_target = (_this select 3) select 1; // Plastic_Pole_EP1_DZ
_objectClasses = DZE_maintainClasses;
_range = DZE_maintainRange; // set the max range for the maintain area
_objects = nearestObjects [_target, _objectClasses, _range];
//filter to only those that have 10% damage
_objects_filtered = [];
_count = 0;
{
if (damage _x >= DZE_DamageBeforeMaint) then {
_objectUID = _x getVariable ["ObjectUID","0"];
_objectID = _x getVariable ["ObjectID","0"];
_objects_filtered set [count _objects_filtered, [_x, _objectID, _objectUID]];
_count = _count + 1;
};
} count _objects;
_objects = _objects_filtered;
// TODO dynamic requirements based on used building parts?
if (_count == 0) exitWith {
format[localize "STR_EPOCH_ACTIONS_22",_count] call dayz_rollingMessages;
DZE_ActionInProgress = false;
s_player_maintain_area = -1;
s_player_maintain_area_preview = -1;
};
_requirements = [];
switch true do {
case (_count <= 10): {_requirements = [["ItemGoldBar10oz",1]]};
case (_count <= 20): {_requirements = [["ItemGoldBar10oz",2]]};
case (_count <= 35): {_requirements = [["ItemGoldBar10oz",3]]};
case (_count <= 50): {_requirements = [["ItemGoldBar10oz",4]]};
case (_count <= 75): {_requirements = [["ItemGoldBar10oz",6]]};
case (_count <= 100): {_requirements = [["ItemBriefcase100oz",1]]};
case (_count <= 175): {_requirements = [["ItemBriefcase100oz",2]]};
case (_count <= 250): {_requirements = [["ItemBriefcase100oz",3]]};
case (_count <= 325): {_requirements = [["ItemBriefcase100oz",4]]};
case (_count <= 400): {_requirements = [["ItemBriefcase100oz",5]]};
case (_count <= 475): {_requirements = [["ItemBriefcase100oz",6]]};
case (_count <= 550): {_requirements = [["ItemBriefcase100oz",7]]};
case (_count <= 625): {_requirements = [["ItemBriefcase100oz",8]]};
case (_count > 625): {_requirements = [["ItemBriefcase100oz",9]]};
};
_option = (_this select 3) select 0;
switch _option do {
case "maintain": {
_missing = "";
_missingQty = 0;
_proceed = true;
{
_itemIn = _x select 0;
_countIn = _x select 1;
_qty = { (_x == _itemIn) || (configName(inheritsFrom(configFile >> "cfgMagazines" >> _x)) == _itemIn) } count magazines player;
if (_qty < _countIn) exitWith { _missing = _itemIn; _missingQty = (_countIn - _qty); _proceed = false; };
} forEach _requirements;
if (_proceed) then {
player playActionNow "Medic";
[player,_range,true,(getPosATL player)] spawn player_alertZombies;
_temp_removed_array = [];
_removed_total = 0;
_tobe_removed_total = 0;
{
_removed = 0;
_itemIn = _x select 0;
_countIn = _x select 1;
_tobe_removed_total = _tobe_removed_total + _countIn;
{
if ((_removed < _countIn) && ((_x == _itemIn) || configName(inheritsFrom(configFile >> "cfgMagazines" >> _x)) == _itemIn)) then {
_num_removed = ([player,_x] call BIS_fnc_invRemove);
_removed = _removed + _num_removed;
_removed_total = _removed_total + _num_removed;
if (_num_removed >= 1) then {
_temp_removed_array set [count _temp_removed_array,_x];
};
};
} forEach magazines player;
} forEach _requirements;
// all required items removed from player gear
if (_tobe_removed_total == _removed_total) then {
format[localize "STR_EPOCH_ACTIONS_4",_count] call dayz_rollingMessages;
PVDZE_maintainArea = [player,1, _objects];
publicVariableServer "PVDZE_maintainArea";
} else {
{player addMagazine _x;} count _temp_removed_array;
format[localize "STR_EPOCH_PLAYER_145",_removed_total,_tobe_removed_total] call dayz_rollingMessages;
};
} else {
_textMissing = getText(configFile >> "CfgMagazines" >> _missing >> "displayName");
format[localize "STR_EPOCH_ACTIONS_6",_missingQty,_textMissing] call dayz_rollingMessages;
};
};
case "preview": {
_cost = "";
{
_itemIn = _x select 0;
_countIn = _x select 1;
_itemText = getText(configFile >> "CfgMagazines" >> _itemIn >> "displayName");
if (_cost != "") then {
_cost = _cost + " and ";
};
_cost = _cost + (str(_countIn) + " of " + _itemText);
} count _requirements;
format[localize "STR_EPOCH_ACTIONS_7",_count,_cost] call dayz_rollingMessages;
};
};
DZE_ActionInProgress = false;
s_player_maintain_area = -1;
s_player_maintain_area_preview = -1;

View File

@@ -1,5 +1,5 @@
createdialog "PlotManagement";
call PlotNearbyHumans;
call PlotGetFriends;
["preview"] call MaintainPlot;
call PlotObjects;
"preview" call MaintainPlot;
call PlotObjects;

View File

@@ -1,4 +1,4 @@
private ["_missing","_missingQty","_proceed","_itemIn","_countIn","_qty","_num_removed","_uniqueID","_removed","_removed_total","_tobe_removed_total","_obj","_objectID","_objectUID","_classname","_location","_dir","_objectCharacterID","_object","_temp_removed_array","_textMissing","_target","_objectClasses","_range","_objects","_requirements","_count","_cost","_itemText","_option"];
private ["_objectID","_objectUID","_target","_objectClasses","_range","_objects","_requirements","_count","_objects_filtered","_ctrl","_itemText","_type","_amount","_success","_wealth","_message1","_message2","_option"];
disableSerialization;
if (DZE_ActionInProgress) exitWith {localize "STR_EPOCH_ACTIONS_2" call dayz_rollingMessages;};
@@ -10,9 +10,8 @@ player removeAction s_player_maintain_area_preview;
s_player_maintain_area_preview = 1;
_target = nearestObject [[player] call FNC_getPos,"Plastic_Pole_EP1_DZ"];
_objectClasses = DZE_maintainClasses;
_range = DZE_PlotPole select 0;
_range = DZE_maintainRange; // set the max range for the maintain area
_objects = nearestObjects [_target, _objectClasses, _range];
_objects_filtered = [];
@@ -20,7 +19,7 @@ _count = 0;
{
if (damage _x >= DZE_DamageBeforeMaint) then {
_objectUID = _x getVariable ["ObjectUID","0"];
_objectID = _x getVariable ["ObjectID","0"];
_objectID = _x getVariable ["ObjectID","0"];
_objects_filtered set [count _objects_filtered, [_x, _objectID, _objectUID]];
_count = _count + 1;
};
@@ -29,120 +28,107 @@ _objects = _objects_filtered;
// TODO dynamic requirements based on used building parts?
if (_count == 0) exitWith {
_ctrl = ((uiNamespace getVariable "PlotManagement") displayCtrl 7012);
_result = format[localize "STR_EPOCH_PLOTMANAGEMENT_MAINTAIN_OBJECTS", _count];
_ctrl ctrlSetText _result;
_ctrl = ((uiNamespace getVariable "PlotManagement") displayCtrl 7013);
_result = format[localize "STR_EPOCH_PLOTMANAGEMENT_NO_MONEY_NEEDED", " "];
_ctrl ctrlSetText _result;
if (DZE_permanentPlot) then {
_ctrl = (uiNamespace getVariable "PlotManagement") displayCtrl 7012;
_ctrl ctrlSetText format[localize "STR_EPOCH_PLOTMANAGEMENT_MAINTAIN_OBJECTS", _count];
_ctrl = (uiNamespace getVariable "PlotManagement") displayCtrl 7013;
_ctrl ctrlSetText format[localize "STR_EPOCH_PLOTMANAGEMENT_NO_MONEY_NEEDED", " "];
} else {
format[localize "STR_EPOCH_ACTIONS_22",_count] call dayz_rollingMessages;
};
DZE_ActionInProgress = false;
s_player_maintain_area = -1;
s_player_maintain_area_preview = -1;
};
_requirements = [];
switch true do {
case (_count <= 10): {_requirements = [["ItemGoldBar10oz",1]]};
case (_count <= 20): {_requirements = [["ItemGoldBar10oz",2]]};
case (_count <= 35): {_requirements = [["ItemGoldBar10oz",3]]};
case (_count <= 50): {_requirements = [["ItemGoldBar10oz",4]]};
case (_count <= 75): {_requirements = [["ItemGoldBar10oz",6]]};
case (_count <= 100): {_requirements = [["ItemBriefcase100oz",1]]};
case (_count <= 175): {_requirements = [["ItemBriefcase100oz",2]]};
case (_count <= 250): {_requirements = [["ItemBriefcase100oz",3]]};
case (_count <= 325): {_requirements = [["ItemBriefcase100oz",4]]};
case (_count <= 400): {_requirements = [["ItemBriefcase100oz",5]]};
case (_count <= 475): {_requirements = [["ItemBriefcase100oz",6]]};
case (_count <= 550): {_requirements = [["ItemBriefcase100oz",7]]};
case (_count <= 625): {_requirements = [["ItemBriefcase100oz",8]]};
case (_count > 625): {_requirements = [["ItemBriefcase100oz",9]]};
_requirements = switch true do {
case (_count <= 10): {["ItemGoldBar10oz",1]};
case (_count <= 20): {["ItemGoldBar10oz",2]};
case (_count <= 35): {["ItemGoldBar10oz",3]};
case (_count <= 50): {["ItemGoldBar10oz",4]};
case (_count <= 75): {["ItemGoldBar10oz",6]};
case (_count <= 100): {["ItemBriefcase100oz",1]};
case (_count <= 175): {["ItemBriefcase100oz",2]};
case (_count <= 250): {["ItemBriefcase100oz",3]};
case (_count <= 325): {["ItemBriefcase100oz",4]};
case (_count <= 400): {["ItemBriefcase100oz",5]};
case (_count <= 475): {["ItemBriefcase100oz",6]};
case (_count <= 550): {["ItemBriefcase100oz",7]};
case (_count <= 625): {["ItemBriefcase100oz",8]};
case (_count > 625): {["ItemBriefcase100oz",9]};
};
_type = _requirements select 0;
_amount = _requirements select 1;
if (Z_SingleCurrency) then {
_amount = _count * 100;
_itemText = CurrencyName;
_wealth = player getVariable[Z_MoneyVariable,0];
} else {
_itemText = getText(configFile >> "CfgMagazines" >> _type >> "displayName");
if ("ItemBriefcase100oz" == _type && _amount > 1) then {
_itemText = _itemText + "s";
};
};
_option = if (typeName _this == "ARRAY") then {_this select 3} else {_this};
_option = _this select 0;
switch _option do {
case "maintain": {
_missing = "";
_missingQty = 0;
_proceed = true;
{
_itemIn = _x select 0;
_countIn = _x select 1;
_qty = { (_x == _itemIn) || (configName(inheritsFrom(configFile >> "cfgMagazines" >> _x)) == _itemIn) } count magazines player;
if (_qty < _countIn) exitWith { _missing = _itemIn; _missingQty = (_countIn - _qty); _proceed = false; };
} forEach _requirements;
case "maintain": {
_success = if (Z_SingleCurrency) then {_amount <= _wealth} else {[[[_type, _amount]],0] call epoch_returnChange};
if (_proceed) then {
if (_success) then {
player playActionNow "Medic";
[player,_range,true,(getPosATL player)] spawn player_alertZombies;
_temp_removed_array = [];
_removed_total = 0;
_tobe_removed_total = 0;
{
_removed = 0;
_itemIn = _x select 0;
_countIn = _x select 1;
_tobe_removed_total = _tobe_removed_total + _countIn;
{
if ((_removed < _countIn) && ((_x == _itemIn) || configName(inheritsFrom(configFile >> "cfgMagazines" >> _x)) == _itemIn)) then {
_num_removed = ([player,_x] call BIS_fnc_invRemove);
_removed = _removed + _num_removed;
_removed_total = _removed_total + _num_removed;
if (_num_removed >= 1) then {
_temp_removed_array set [count _temp_removed_array,_x];
};
};
} forEach magazines player;
} forEach _requirements;
if (Z_SingleCurrency) then {
player setVariable[Z_MoneyVariable,(_wealth - _amount),true];
call player_forceSave;
};
// all required items removed from player gear
if (_tobe_removed_total == _removed_total) then {
format[localize "STR_EPOCH_ACTIONS_4", _count] call dayz_rollingMessages;
PVDZE_maintainArea = [player,1,_objects];
publicVariableServer "PVDZE_maintainArea";
_ctrl = ((uiNamespace getVariable "PlotManagement") displayCtrl 7012);
_result = format[localize "STR_EPOCH_PLOTMANAGEMENT_OBJECTS_MAINTAINED_SUCCESS", _count];
_ctrl ctrlSetText _result;
_ctrl = ((uiNamespace getVariable "PlotManagement") displayCtrl 7013);
_result = format[localize "STR_EPOCH_PLOTMANAGEMENT_PRICE_MAINTAINED_SUCCESS", (_requirements select 0) select 1, (_requirements select 0) select 0];
_ctrl ctrlSetText _result;
} else {
{player addMagazine _x;} count _temp_removed_array;
format[localize "STR_EPOCH_ACTIONS_5",_removed_total,_tobe_removed_total] call dayz_rollingMessages;
PVDZE_maintainArea = [player,1,_objects];
publicVariableServer "PVDZE_maintainArea";
systemChat format[localize "STR_EPOCH_ACTIONS_4", _count];
_message1 = format[localize "STR_EPOCH_PLOTMANAGEMENT_OBJECTS_MAINTAINED_SUCCESS", _count];
_message2 = format[localize "STR_EPOCH_PLOTMANAGEMENT_PRICE_MAINTAINED_SUCCESS", _amount, _itemText];
if (DZE_permanentPlot) then {
_ctrl = (uiNamespace getVariable "PlotManagement") displayCtrl 7012;
_ctrl ctrlSetText _message1;
_ctrl = (uiNamespace getVariable "PlotManagement") displayCtrl 7013;
_ctrl ctrlSetText _message2;
} else {
_message2 call dayz_rollingMessages;
_message1 call dayz_rollingMessages;
};
} else {
_textMissing = getText(configFile >> "CfgMagazines" >> _missing >> "displayName");
_ctrl = ((uiNamespace getVariable "PlotManagement") displayCtrl 7012);
_result = format[localize "STR_EPOCH_PLOTMANAGEMENT_OBJECTS_MAINTAINED_FAILED", _count];
_ctrl ctrlSetText _result;
_ctrl = ((uiNamespace getVariable "PlotManagement") displayCtrl 7013);
_result = format[localize "STR_EPOCH_PLOTMANAGEMENT_MONEY_NEEDED_FAILED", (_requirements select 0) select 1, (_requirements select 0) select 0];
_ctrl ctrlSetText _result;
format[localize "STR_EPOCH_ACTIONS_6", _missingQty, _textMissing] call dayz_rollingMessages;
_message1 = format[localize "STR_EPOCH_PLOTMANAGEMENT_OBJECTS_MAINTAINED_FAILED", _count];
_message2 = format[localize "STR_EPOCH_PLOTMANAGEMENT_MONEY_NEEDED_FAILED", _amount, _itemText];
if (DZE_permanentPlot) then {
_ctrl = (uiNamespace getVariable "PlotManagement") displayCtrl 7012;
_ctrl ctrlSetText _message1;
_ctrl = (uiNamespace getVariable "PlotManagement") displayCtrl 7013;
_ctrl ctrlSetText _message2;
} else {
_message2 call dayz_rollingMessages;
_message1 call dayz_rollingMessages;
};
};
};
case "preview": {
_cost = "";
{
_itemIn = _x select 0;
_countIn = _x select 1;
_itemText = getText(configFile >> "CfgMagazines" >> _itemIn >> "displayName");
if (_cost != "") then {
_cost = _cost + " and "; //TODO: localize?
};
_cost = _cost + (str(_countIn) + " of " + _itemText); //TODO: localize?
} count _requirements;
format[localize "STR_EPOCH_ACTIONS_7", _count, _cost] call dayz_rollingMessages;
_ctrl = ((uiNamespace getVariable "PlotManagement") displayCtrl 7012);
_result = format[localize "STR_EPOCH_PLOTMANAGEMENT_MAINTAIN_OBJECTS", _count];
_ctrl ctrlSetText _result;
_ctrl = ((uiNamespace getVariable "PlotManagement") displayCtrl 7013);
_result = format[localize "STR_EPOCH_PLOTMANAGEMENT_MAINTAIN_PRICE", (_requirements select 0) select 1, (_requirements select 0) select 0];
_ctrl ctrlSetText _result;
_message1 = format[localize "STR_EPOCH_PLOTMANAGEMENT_MAINTAIN_OBJECTS", _count];
_message2 = format[localize "STR_EPOCH_PLOTMANAGEMENT_MAINTAIN_PRICE", _amount, _itemText];
if (DZE_permanentPlot) then {
_ctrl = (uiNamespace getVariable "PlotManagement") displayCtrl 7012;
_ctrl ctrlSetText _message1;
_ctrl = (uiNamespace getVariable "PlotManagement") displayCtrl 7013;
_ctrl ctrlSetText _message2;
} else {
_message2 call dayz_rollingMessages;
_message1 call dayz_rollingMessages;
};
};
};

View File

@@ -1,122 +0,0 @@
private ["_newWealth","_missing","_missingQty","_proceed","_itemIn","_countIn","_target","_objectClasses","_range","_objects","_requirements","_count","_cost","_option"];
disableSerialization;
if (DZE_ActionInProgress) exitWith { cutText [(localize "STR_EPOCH_ACTIONS_2") , "PLAIN DOWN"]; };
DZE_ActionInProgress = true;
player removeAction s_player_maintain_area;
s_player_maintain_area = 1;
player removeAction s_player_maintain_area_preview;
s_player_maintain_area_preview = 1;
_target = nearestObject [[player] call FNC_getPos,"Plastic_Pole_EP1_DZ"];
_objectClasses = DZE_maintainClasses;
_range = DZE_PlotPole select 0;
_objects = nearestObjects [_target, _objectClasses, _range];
_objects_filtered = [];
{
if (damage _x >= DZE_DamageBeforeMaint) then {
_objectUID = _x getVariable ["ObjectUID","0"];
_objectID = _x getVariable ["ObjectID","0"];
_objects_filtered set [count _objects_filtered, [_x, _objectID, _objectUID]];
_count = _count + 1;
};
} count _objects;
_objects = _objects_filtered;
// TODO dynamic requirements based on used building parts?
if (_count == 0) exitWith {
_ctrl = ((uiNamespace getVariable "PlotManagement") displayCtrl 7012);
_result = format["Objects to maintain: %1" , _count];
_ctrl ctrlSetText _result;
_ctrl = ((uiNamespace getVariable "PlotManagement") displayCtrl 7013);
_result = format["Price to maintain: %1 %2" , 0, CurrencyName];
_ctrl ctrlSetText _result;
DZE_ActionInProgress = false;
s_player_maintain_area = -1;
s_player_maintain_area_preview = -1;
};
_theCost = _count * 1;
_requirements = [[CurrencyName,_theCost]];
_option = _this select 0;
switch _option do {
case "maintain": {
_wealth = player getVariable[Z_MoneyVariable,0];
_missing = "";
_missingQty = 0;
_proceed = true;
{
_itemIn = _x select 0;
_countIn = _x select 1;
if (_wealth < _countIn) exitWith { _missing = _itemIn; _missingQty = (_countIn - _wealth); _proceed = false; };
} count _requirements;
if (_proceed) then {
_newWealth = (_wealth - _countIn);
player playActionNow "Medic";
[player,_range,true,(getPosATL player)] spawn player_alertZombies;
player setVariable[Z_MoneyVariable,_newWealth,true];
call player_forceSave;
PVDZE_maintainArea = [player,1,_objects];
publicVariableServer "PVDZE_maintainArea";
cutText [format[(localize "STR_EPOCH_ACTIONS_4"), _count], "PLAIN DOWN", 5];
_ctrl = ((uiNamespace getVariable "PlotManagement") displayCtrl 7012);
_result = format["SUCCESS : Objects maintained: %1" , _count];
_ctrl ctrlSetText _result;
_ctrl = ((uiNamespace getVariable "PlotManagement") displayCtrl 7013);
_result = format["SUCCESS : Price maintained: %1 %2" , _theCost, CurrencyName];
_ctrl ctrlSetText _result;
} else {
_ctrl = ((uiNamespace getVariable "PlotManagement") displayCtrl 7012);
_result = format["FAILED: Objects to maintain: %1" , _count];
_ctrl ctrlSetText _result;
_ctrl = ((uiNamespace getVariable "PlotManagement") displayCtrl 7013);
_result = format["FAILED: Price to maintain: %1 %2" , _theCost, CurrencyName];
_ctrl ctrlSetText _result;
cutText [format[(localize "STR_EPOCH_ACTIONS_6"), _missingQty, CurrencyName], "PLAIN DOWN"];
};
};
case "preview": {
_cost = "";
{
_itemIn = _x select 0;
_countIn = _x select 1;
if (_cost != "") then {
_cost = _cost + " and ";
};
_cost = _cost + (str(_countIn) + " " + CurrencyName);
} count _requirements;
cutText [format[(localize "STR_EPOCH_ACTIONS_7"), _count, _cost], "PLAIN DOWN"];
_ctrl = ((uiNamespace getVariable "PlotManagement") displayCtrl 7012);
_result = format["Objects to maintain: %1" , _count];
_ctrl ctrlSetText _result;
_ctrl = ((uiNamespace getVariable "PlotManagement") displayCtrl 7013);
_result = format["Price to maintain: %1 %2" , _theCost, CurrencyName];
_ctrl ctrlSetText _result;
};
};
DZE_ActionInProgress = false;
s_player_maintain_area = -1;
s_player_maintain_area_preview = -1;

View File

@@ -2,14 +2,18 @@ private ["_pos","_plots","_thePlot","_inList","_toAdd","_friends"];
_pos = _this select 0;
if (_pos < 0) exitWith {};
_toAdd = (Humans select _pos);
_plots = nearestObjects [[player] call FNC_getPos, ["Plastic_Pole_EP1_DZ"],15];
_thePlot = _plots select 0;
_friends = _thePlot getVariable ["plotfriends",[]];
_inList = false;
{ if ((_x select 0) == (_toAdd select 0)) exitWith { _inList = true; }; } count _friends;
if (_inList) exitWith {localize "STR_EPOCH_PLOTMANAGEMENT_ADDFRIEND_ALREADYONTHELIST" call dayz_rollingMessages};
if ((count _friends) == DZE_MaxPlotFriends) exitWith { format[localize "STR_EPOCH_PLOTMANAGEMENT_ADDFRIEND_FRIENDLIMIT", DZE_MaxPlotFriends] call dayz_rollingMessages;};
_friends set [(count _friends), _toAdd];
_thePlot setVariable ["plotfriends", _friends, true];
PVDZ_veh_Save = [_thePlot,"gear"];
@@ -18,6 +22,5 @@ if (isServer) then {
} else {
publicVariableServer "PVDZ_veh_Save";
};
call PlotGetFriends;
call PlotNearbyHumans;
call PlotNearbyHumans;

View File

@@ -6,7 +6,4 @@ _thePlot = _plots select 0;
_friendlies = _thePlot getVariable ["plotfriends", []];
{
lbAdd [7002, toString (_x select 1)];
} forEach _friendlies; // count causes Error Type Number, expected Bool here
} forEach _friendlies;

View File

@@ -10,4 +10,4 @@ Humans = [];
Humans = Humans + [[_friendUID,toArray _friendName]];
lbAdd [7001, _friendName];
};
} forEach _closePeople; // count causes Error Type Number, expected Bool here
} forEach _closePeople;

View File

@@ -1,19 +1,19 @@
private ["_range","_buildables","_count","_colour","_result","_ctrl"];
private ["_range","_buildables","_count","_colour","_ctrl","_target"];
disableSerialization;
_range = DZE_PlotPole select 0;
_buildables = DZE_maintainClasses + DZE_LockableStorage + ["DZ_buildables","DZ_storage_base"];
_count = count (nearestObjects [[player] call FNC_getPos,_buildables,_range]);
_target = nearestObject [[player] call FNC_getPos,"Plastic_Pole_EP1_DZ"];
_buildables = DZE_maintainClasses;
_count = count (nearestObjects [_target,_buildables,_range]);
_colour = "#ffffff";
if (_count / DZE_BuildingLimit * 100 < 40) then {
_colour = "#00ff00";
_colour = "#00ff00";
};
if (_count / DZE_BuildingLimit * 100 > 75) then {
_colour = "#ff0000";
_colour = "#ff0000";
};
_ctrl = ((uiNamespace getVariable "PlotManagement") displayCtrl 7014);
_result = format["<t color='%3'>%1 / %2</t>" , _count, DZE_BuildingLimit,_colour];
_ctrl ctrlSetStructuredText parseText _result;
_ctrl ctrlSetStructuredText parseText format["<t color='%3'>%1 / %2</t>" , _count, DZE_BuildingLimit,_colour];

View File

@@ -8,7 +8,7 @@ _friends = _thePlot getVariable ["plotfriends", []];
_toRemove = (_friends select _pos);
_newList = [];
{
if(_x select 0 != _toRemove select 0) then {
if (_x select 0 != _toRemove select 0) then {
_newList set [(count _newList), _x];
};
} count _friends;

View File

@@ -1,30 +1,28 @@
//Zero Remorse, big thanks to their scripter for this!
private ["_speed","_density","_model","_thePlot","_center","_radius","_angle","_count","_axis","_obj","_idx","_a","_b"];
//-----------------------------------------------------------------------------------------
_speed = 4; // multiplier for speed of sphere rotation/wobble
_density = 3; // density of markers per ring
_model = "Sign_sphere100cm_EP1"; // marker model to use on rings
// Possible ones to use :: Sign_sphere10cm_EP1 Sign_sphere25cm_EP1 Sign_sphere100cm_EP1
//-----------------------------------------------------------------------------------------
//
_thePlot = (nearestObjects [player, ["Plastic_Pole_EP1_DZ"],15]) select 0;
_center = getPosASL _thePlot; _radius = DZE_PlotPole select 0;
_obj = false; _tmp = -1;
//-----------------------------------------------------------------------------------------
if (!isNil "PP_Marks") then {
if (((PP_Marks select 0) distance _thePlot) < 10) then { _obj = true; };
_tmp = (PP_Marks select 0) distance _thePlot;
{ deleteVehicle _x; } count PP_Marks; PP_Marks = nil;
};
//-----------------------------------------------------------------------------------------
if ((isNil "PP_Marks") && (!_obj)) then {
PP_Marks = []; _count = round((2 * pi * _radius) / _density);
//--------------------------------------------------------------------------------
_obj = "Sign_sphere10cm_EP1" createVehicleLocal [0,0,0]; // PARENT marker on pole
_obj setPosASL [_center select 0, _center select 1, _center select 2];
_obj setObjectTexture [0, "#(argb,16,16,1)color(0,1,0,0.4)"]; _axis = _obj;
_obj setVectorUp [0, 0, 0]; PP_Marks set [count PP_Marks, _obj];
//--------------------------------------------------------------------------------
_angle = 0;
for "_idx" from 0 to _count do {
_a = (_center select 0) + (sin(_angle)*_radius);
@@ -33,27 +31,22 @@ if ((isNil "PP_Marks") && (!_obj)) then {
_obj setPosASL [_a, _b, _center select 2];
_obj setObjectTexture [0, "#(argb,16,16,1)color(0,1,0,0.4)"];
_obj attachTo [_axis]; PP_Marks set [count PP_Marks, _obj];
//----------------------------------------------------------------------------
_a = (_center select 0) + (sin(_angle)*_radius);
_b = (_center select 2) + (cos(_angle)*_radius);
_obj = _model createVehicleLocal [0,0,0];
_obj setPosASL [_a, _center select 1, _b];
_obj setObjectTexture [0, "#(argb,16,16,1)color(0,1,0,0.4)"];
_obj attachTo [_axis]; PP_Marks set [count PP_Marks, _obj];
//----------------------------------------------------------------------------
_angle = _angle + (360/_count);
};
//----------------------------------------------------------------------------
_angle = (360/_count);
for "_idx" from 0 to (_count - 2) do {
//----------------------------------------------------------------------------
_a = (_center select 1) + (sin(_angle)*_radius);
_b = (_center select 2) + (cos(_angle)*_radius);
_obj = _model createVehicleLocal [0,0,0];
_obj setPosASL [_center select 0, _a, _b];
_obj setObjectTexture [0, "#(argb,16,16,1)color(0,1,0,0.4)"];
_obj attachTo [_axis]; PP_Marks set [count PP_Marks, _obj];
//----------------------------------------------------------------------------
_angle = _angle + (360/_count);
};
_angle = (360/_count); _axis setDir 45;
@@ -64,18 +57,12 @@ if ((isNil "PP_Marks") && (!_obj)) then {
_obj setPosASL [_a, _center select 1, _b];
_obj setObjectTexture [0, "#(argb,16,16,1)color(0,1,0,0.4)"];
_obj attachTo [_axis]; PP_Marks set [count PP_Marks, _obj];
//----------------------------------------------------------------------------
_a = (_center select 1) + (sin(_angle)*_radius);
_b = (_center select 2) + (cos(_angle)*_radius);
_obj = _model createVehicleLocal [0,0,0];
_obj setPosASL [_center select 0, _a, _b];
_obj setObjectTexture [0, "#(argb,16,16,1)color(0,1,0,0.4)"];
_obj attachTo [_axis]; PP_Marks set [count PP_Marks, _obj];
//----------------------------------------------------------------------------
_angle = _angle + (360/_count);
};
//--------------------------------------------------------------------------------
//--------------------------------------------------------------------------------
};
//------------------------------------------------------------------------------------
//------------------------------------------------------------------------------------

View File

@@ -55,7 +55,7 @@ if(_IsNearPlot == 0) then {
};
if(!_canBuild) exitWith { DZE_ActionInProgress = false; format[localize "STR_EPOCH_PLAYER_135",_needText,_distance] call dayz_rollingMessages; [_canBuild, _isPole];};
// Also count safes, lockboxes, vanilla buildables, tents and stashes against DZE_BuildingLimit
_buildables = DZE_maintainClasses + DZE_LockableStorage + ["DZ_buildables","DZ_storage_base"];
_center = if (isNull _nearestPole) then {_pos} else {_nearestPole};
if ((count (nearestObjects [_center,_buildables,_distance])) >= DZE_BuildingLimit) exitWith {DZE_ActionInProgress = false; format[localize "str_epoch_player_41",_distance] call dayz_rollingMessages; [false, _isPole];};

View File

@@ -20,9 +20,6 @@ _isHeadHit = (_hit == "head_hit");
_isPlayer = (isPlayer _source);
_isZombieHit = _ammo == "zombie";
//Ignore none part dmg.
if (_hit == "") exitwith { 0 };
_falling = (((_hit == "legs") AND {(_source==_unit)}) AND {((_ammo=="") AND {(Dayz_freefall select 1 > 3)})});
//Simple hack to help with a few issues from direct damage to physic based damage. ***until 2.0***
@@ -48,7 +45,7 @@ _falling = (((_hit == "legs") AND {(_source==_unit)}) AND {((_ammo=="") AND {(Da
if (_ammo == "") exitwith { _end = true; };
//If _source contains no object exit. But lets not exit if the unit returns player. Maybe its his own fault.
if (isNull _source) exitwith { _end = true; };
if (isNull _source) then { _end = true; };
};
@@ -61,7 +58,7 @@ if (_unit == player) then {
_unit setVariable["startcombattimer", 1];
_unit setVariable["inCombat", 1, true];
if (_hit == "") then
if (_hit == "") exitWith //Ignore none part dmg. Exit after processing humanity hit
{
if ((_source != player) and _isPlayer && alive player) then
{
@@ -181,6 +178,9 @@ if (_unit == player) then {
if (dayz_lastDamageSource != "none") then {dayz_lastDamageTime = diag_tickTime;};
};
//Ignore none part dmg. Exit after processing humanity hit
if (_hit == "") exitWith { 0 };
//Pure base blood damage
_scale = 200;

View File

@@ -646,8 +646,8 @@ if (!isNull _cursorTarget && !_inVehicle && !_isPZombie && (player distance _cur
};
} else {
if (s_player_maintain_area < 0) then {
s_player_maintain_area = player addAction [format["<t color='#ff0000'>%1</t>",localize "STR_EPOCH_ACTIONS_MAINTAREA"], "\z\addons\dayz_code\actions\maintain_area.sqf", ["maintain",_cursorTarget], 5, false];
s_player_maintain_area_preview = player addAction [format["<t color='#ff0000'>%1</t>",localize "STR_EPOCH_ACTIONS_MAINTPREV"], "\z\addons\dayz_code\actions\maintain_area.sqf", ["preview",_cursorTarget], 5, false];
s_player_maintain_area = player addAction [format["<t color='#ff0000'>%1</t>",localize "STR_EPOCH_ACTIONS_MAINTAREA"], "\z\addons\dayz_code\actions\plotManagement\maintain_area.sqf", "maintain", 5, false];
s_player_maintain_area_preview = player addAction [format["<t color='#ff0000'>%1</t>",localize "STR_EPOCH_ACTIONS_MAINTPREV"], "\z\addons\dayz_code\actions\plotManagement\maintain_area.sqf", "preview", 5, false];
};
};
_PlotsmarkersNear = count (_cursorTarget nearEntities ["Land_coneLight", DZE_PlotPole select 0]);

View File

@@ -29,7 +29,7 @@ if (_ammo isKindOf "Hatchet_Swing_Ammo" || _ammo isKindOf "Chainsaw_Swing_Ammo")
// damage must be going down
_damage = damage _tree;
if (DZE_TEMP_treedmg < _damage) then {
if (_damage < 0.99 && {(random 1) > 0.7}) then {
if (_damage < 0.99 && {(random 1) > 0.9}) then {
PVDZ_objgather_Knockdown = [_tree,player]; // Ask server to setDamage on tree
publicVariableServer "PVDZ_objgather_Knockdown";
};

View File

@@ -1,4 +1,4 @@
/****************************************************************************
/****************************************************************************
Copyright (C) 2010 Team ~R3F~
This program is free software under the terms of the GNU General Public License version 3.
You should have received a copy of the GNU General Public License
@@ -76,6 +76,30 @@ class ItemKnife
{
weight = 0.1;
};
class ItemKnife5
{
weight = 0.1;
};
class ItemKnife4
{
weight = 0.1;
};
class ItemKnife3
{
weight = 0.1;
};
class ItemKnife2
{
weight = 0.1;
};
class ItemKnife1
{
weight = 0.1;
};
class ItemKnifeBlunt
{
weight = 0.1;
};
class MeleeCrowbar
{
weight = 1;
@@ -125,9 +149,33 @@ class ItemSledge
weight = 9.1;
};
class ItemMatchbox
{
weight = 0.007;
};
class Item5Matchbox
{
weight = 0.006;
};
class Item4Matchbox
{
weight = 0.005;
};
class Item3Matchbox
{
weight = 0.004;
};
class Item2Matchbox
{
weight = 0.003;
};
class Item1Matchbox
{
weight = 0.002;
};
class ItemMatchboxEmpty
{
weight = 0.001;
};
class ItemToolbox
{
weight = 1;
@@ -155,4 +203,8 @@ class ItemShovel
class ItemShovelBroken
{
weight = 1;
};
};
class ItemFishingPole
{
weight = 1;
};

View File

@@ -195,7 +195,7 @@ if (!isDedicated) then {
PlotRemoveFriend = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\plotManagement\plotRemoveFriend.sqf";
PlotObjects = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\plotManagement\plotObjects.sqf";
PlotPreview = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\plotManagement\plotToggleMarkers.sqf";
MaintainPlot = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\plotManagement\maintain_area.sqf"; // use maintain_areaSC.sqf for single currency
MaintainPlot = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\plotManagement\maintain_area.sqf";
DoorGetFriends = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\doorManagement\doorGetFriends.sqf";
DoorNearbyHumans = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\doorManagement\doorNearbyHumans.sqf";
DoorAddFriend = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\doorManagement\doorAddFriend.sqf";

View File

@@ -505,7 +505,7 @@ DZE_REPLACE_WEAPONS = [["Crossbow","DMR","M14_EP1","SVD","SVD_CAMO"],["Crossbow_
DZE_LockableStorage = ["VaultStorage","VaultStorageLocked","LockboxStorageLocked","LockboxStorage"];
DZE_LockedStorage = ["VaultStorageLocked","LockboxStorageLocked"];
DZE_UnLockedStorage = ["VaultStorage","LockboxStorage"];
DZE_maintainClasses = ["ModularItems","DZE_Housebase","LightPole_DZ","BuiltItems","Generator_DZ","Plastic_Pole_EP1_DZ","Fence_corrugated_DZ","CanvasHut_DZ","ParkBench_DZ","MetalGate_DZ","StickFence_DZ","DesertCamoNet_DZ","ForestCamoNet_DZ","DesertLargeCamoNet_DZ","ForestLargeCamoNet_DZ","DeerStand_DZ","Scaffolding_DZ","FireBarrel_DZ"];
DZE_maintainClasses = ["ModularItems","DZE_Housebase","LightPole_DZ","BuiltItems","Generator_DZ","DZ_buildables","Plastic_Pole_EP1_DZ","Fence_corrugated_DZ","CanvasHut_DZ","ParkBench_DZ","MetalGate_DZ","StickFence_DZ","DesertCamoNet_DZ","ForestCamoNet_DZ","DesertLargeCamoNet_DZ","ForestLargeCamoNet_DZ","DeerStand_DZ","Scaffolding_DZ","FireBarrel_DZ"];
DZE_DoorsLocked = ["Land_DZE_GarageWoodDoorLocked","Land_DZE_LargeWoodDoorLocked","Land_DZE_WoodDoorLocked","CinderWallDoorLocked_DZ","CinderWallDoorSmallLocked_DZ"];
// List of removable items that require crowbar
DZE_isRemovable = ["Fence_corrugated_DZ","M240Nest_DZ","ParkBench_DZ","Plastic_Pole_EP1_DZ","FireBarrel_DZ","Scaffolding_DZ"];

File diff suppressed because it is too large Load Diff