Move fix tool to epoch crafting

Move player_fixHatchet to player_craftItem. Also add some more broken tools and some more options to repair tools.
This commit is contained in:
AirwavesMan
2020-06-10 14:00:32 +02:00
parent a69948d546
commit 1b412ab599
15 changed files with 234 additions and 15 deletions

View File

@@ -303,6 +303,7 @@ class CfgWeapons
#include "Tools\Binocular.hpp"
#include "Tools\NVG.hpp"
#include "Tools\BinocularVector.hpp"
#include "Tools\Chainsaw.hpp"
#include "Tools\Map.hpp"

View File

@@ -2,3 +2,13 @@ class Binocular : Default
{
modelOptics = "z\addons\dayz_communityweapons\binocular\2dscope_binocular.p3d";
};
class BinocularBroken : Default
{
scope = 2;
type = 4096;
displayName = $STR_EQUIP_BROKEN_BINOCULAR;
descriptionShort = $STR_EQUIP_BROKEN_BINOCULAR_DESC;
model = "\ca\weapons\dalekohled_proxy";
picture = "\dayz_epoch_c\icons\tools\ItemBinocularBroken.paa";
};

View File

@@ -0,0 +1,24 @@
class Binocular_VectorBroken : Default
{
scope = 2;
type = 4096;
displayName = $STR_EQUIP_BROKEN_BINOCULARVECTOR;
descriptionShort = $STR_EQUIP_BROKEN_BINOCULARVECTOR_DESC;
model = "\ca\weapons_E\vector\vector21dt";
picture = "\dayz_epoch_c\icons\tools\ItemBinocularVectorBroken.paa";
class ItemActions
{
class Repair
{
text = $STR_ACTIONS_FIX_BIONCULARVECTOR;
script = ";['Repair','CfgWeapons', _id] spawn player_craftItem;";
neednearby[] = {};
requiretools[] = {"ItemSolder_DZE"};
output[] = {};
outputweapons[] = {"Binocular_Vector"};
input[] = {{"equip_floppywire",1},{"equip_scrapelectronics",1}};
inputweapons[] = {"Binocular_VectorBroken"};
};
};
};

View File

@@ -45,4 +45,19 @@ class ItemCrowbarBent : ItemCore
picture = "\dayz_epoch_c\icons\tools\ItemCrowbarBroken.paa";
displayName = $STR_EQUIP_NAME_CROWBARBENT;
descriptionShort = $STR_EQUIP_DESC_CROWBARBENT;
class ItemActions
{
class Repair
{
text = $STR_ACTIONS_FIX_CROWBAR;
script = ";['Repair','CfgWeapons', _id] spawn player_craftItem;";
neednearby[] = {"fire"};
requiretools[] = {"ItemToolbox"};
output[] = {};
outputweapons[] = {"ItemCrowbar"};
input[] = {{"PartGeneric",1}};
inputweapons[] = {"ItemCrowbarBent"};
};
};
};

View File

@@ -14,4 +14,19 @@ class ItemEtoolBroken : ItemCore
picture = "\dayz_epoch_c\icons\tools\ItemEtoolBroken.paa";
displayName = $STR_EQUIP_NAME_1_BROKEN;
descriptionShort = $STR_EQUIP_DESC_1_BROKEN;
class ItemActions
{
class Repair
{
text = $STR_ACTIONS_FIX_ETOOL;
script = ";['Repair','CfgWeapons', _id] spawn player_craftItem;";
neednearby[] = {};
requiretools[] = {};
output[] = {};
outputweapons[] = {"ItemEtool"};
input[] = {{"equip_duct_tape",1},{"equip_lever",1}};
inputweapons[] = {"ItemEtoolBroken"};
};
};
};

View File

@@ -45,4 +45,19 @@ class ItemFishingPoleBroken : ItemCore
picture = "\dayz_epoch_c\icons\tools\ItemFishingpoleBroken.paa";
displayName = $STR_ITEM_NAME_FISHINGPOLEBROKEN;
descriptionShort = $STR_ITEM_DESC_FISHINGPOLE_BROKEN;
class ItemActions
{
class Repair
{
text = $STR_ACTIONS_FIX_FISHINGPOLE;
script = ";['Repair','CfgWeapons', _id] spawn player_craftItem;";
neednearby[] = {};
requiretools[] = {};
output[] = {};
outputweapons[] = {"ItemFishingPole"};
input[] = {{"equip_duct_tape",1},{"equip_lever",1}};
inputweapons[] = {"ItemFishingPoleBroken"};
};
};
};

View File

@@ -10,4 +10,19 @@ class ItemGPSBroken_DZE : ItemCore
model = "z\addons\dayz_communityassets\models\gps.p3d";
picture = "\dayz_epoch_c\icons\tools\ItemGPSBroken.paa";
descriptionShort = $STR_EQUIP_BROKEN_GPS_DESC;
class ItemActions
{
class Repair
{
text = $STR_ACTIONS_FIX_GPS;
script = ";['Repair','CfgWeapons', _id] spawn player_craftItem;";
neednearby[] = {};
requiretools[] = {"ItemSolder_DZE"};
output[] = {};
outputweapons[] = {"ItemGPS"};
input[] = {{"equip_floppywire",1},{"equip_scrapelectronics",1}};
inputweapons[] = {"ItemGPSBroken_DZE"};
};
};
};

View File

@@ -33,14 +33,19 @@ class ItemHatchetBroken : ItemCore
model = "\dayz_equip\models\hatchet.p3d";
displayName = $STR_name_ItemHatchetBroken;
descriptionShort = $STR_desc_ItemHatchetBroken;
fixedTool = "ItemHatchet";
class ItemActions
{
class Repair
{
text = $STR_ACTIONS_FIX_HATCHET;
script="spawn player_fixHatchet;";
script = ";['Repair','CfgWeapons', _id] spawn player_craftItem;";
neednearby[] = {};
requiretools[] = {};
output[] = {};
outputweapons[] = {"ItemHatchet"};
input[] = {{"equip_duct_tape",1},{"equip_lever",1}};
inputweapons[] = {"ItemHatchetBroken"};
};
};
};

View File

@@ -11,11 +11,27 @@ class NVGoggles_DZE: NVGoggles
model = "\dayz_epoch_c\items\nvg\nvg_dzn.p3d";
};
class ItemNVGBroken_DZE : ItemCore
class ItemNVGBroken_DZE : Default
{
scope = 2;
type = 4096;
displayName = $STR_EQUIP_BROKEN_NV;
model = "\dayz_epoch_c\items\nvg\nvg_dzn.p3d";
picture = "\dayz_epoch_c\icons\tools\ItemNightVisionBroken.paa";
descriptionShort = $STR_EQUIP_BROKEN_NV_DESC;
class ItemActions
{
class Repair
{
text = $STR_ACTIONS_FIX_NIGHTVISION;
script = ";['Repair','CfgWeapons', _id] spawn player_craftItem;";
neednearby[] = {};
requiretools[] = {"ItemSolder_DZE"};
output[] = {};
outputweapons[] = {"NVGoggles"};
input[] = {{"equip_floppywire",1},{"equip_scrapelectronics",1}};
inputweapons[] = {"ItemNVGBroken_DZE"};
};
};
};

View File

@@ -23,14 +23,19 @@ class ItemPickaxeBroken : ItemCore
picture = "\dayz_epoch_c\icons\tools\ItemPickaxeBroken.paa";
displayName = $STR_name_ItemPickaxeBroken;
descriptionShort = $STR_desc_ItemPickaxeBroken;
fixedTool = "ItemPickaxe";
class ItemActions
{
class Repair
{
text = $STR_ACTIONS_FIX_PICKAXE;
script = "spawn player_fixHatchet;";
script = ";['Repair','CfgWeapons', _id] spawn player_craftItem;";
neednearby[] = {};
requiretools[] = {};
output[] = {};
outputweapons[] = {"ItemPickaxe"};
input[] = {{"equip_duct_tape",1},{"equip_lever",1}};
inputweapons[] = {"ItemPickaxeBroken"};
};
};
};

View File

@@ -18,4 +18,19 @@ class ItemRadioBroken_DZE : ItemCore
model = "\nst\ns_dayz\items\radio\radio_dzn.p3d";
picture = "\dayz_epoch_c\icons\tools\ItemRadioBroken.paa";
descriptionShort = $STR_EQUIP_BROKEN_RADIO_DESC;
class ItemActions
{
class Repair
{
text = $STR_ACTIONS_FIX_RADIO;
script = ";['Repair','CfgWeapons', _id] spawn player_craftItem;";
neednearby[] = {};
requiretools[] = {"ItemSolder_DZE"};
output[] = {};
outputweapons[] = {"ItemRadio"};
input[] = {{"equip_floppywire",1},{"equip_scrapelectronics",1}};
inputweapons[] = {"ItemRadioBroken_DZE"};
};
};
};

View File

@@ -14,4 +14,19 @@ class ItemShovelBroken : ItemCore
picture = "\dayz_epoch_c\icons\tools\ItemShovelBroken.paa";
displayName = $STR_EQUIP_NAME_1b_BROKEN;
descriptionShort = $STR_EQUIP_DESC_1b_BROKEN;
class ItemActions
{
class Repair
{
text = $STR_ACTIONS_FIX_SHOVEL;
script = ";['Repair','CfgWeapons', _id] spawn player_craftItem;";
neednearby[] = {};
requiretools[] = {};
output[] = {};
outputweapons[] = {"ItemShovel"};
input[] = {{"equip_duct_tape",1},{"equip_lever",1}};
inputweapons[] = {"ItemShovelBroken"};
};
};
};

View File

@@ -33,6 +33,21 @@ class ItemSledgeBroken: ItemCore
picture = "\dayz_epoch_c\icons\tools\ItemSledge1Broken.paa";
displayName = $STR_name_ItemSledgeHammerBroken;
descriptionShort = $STR_desc_ItemSledgeHammerBroken;
class ItemActions
{
class Repair
{
text = $STR_ACTIONS_FIX_SLEDGE_HAMMER;
script = ";['Repair','CfgWeapons', _id] spawn player_craftItem;";
neednearby[] = {};
requiretools[] = {};
output[] = {};
outputweapons[] = {"ItemSledge"};
input[] = {{"equip_duct_tape",1},{"ItemSledgeHandle",1}};
inputweapons[] = {"ItemSledgeBroken"};
};
};
};
//Vanilla sledge is using a different model.
@@ -53,14 +68,19 @@ class ItemSledgeHammerBroken : ItemCore
picture = "\dayz_epoch_c\icons\tools\ItemSledge2Broken.paa";
displayName = $STR_name_ItemSledgeHammerBroken;
descriptionShort = $STR_desc_ItemSledgeHammerBroken;
fixedTool = "ItemSledgeHammer";
class ItemActions
{
class Toolbelt
class Repair
{
text = $STR_ACTIONS_FIX_SLEDGE_HAMMER;
script = "spawn player_fixHatchet;";
script = ";['Repair','CfgWeapons', _id] spawn player_craftItem;";
neednearby[] = {};
requiretools[] = {};
output[] = {};
outputweapons[] = {"ItemSledgeHammer"};
input[] = {{"equip_duct_tape",1},{"equip_lever",1}};
inputweapons[] = {"ItemSledgeHammerBroken"};
};
};
};

View File

@@ -116,11 +116,11 @@ if (!isDedicated) then {
call compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\player_switchWeapon.sqf";
player_gather = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\player_gather.sqf";
player_tearClothes = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\player_tearClothes.sqf";
player_fixHatchet = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\player_fixTools.sqf";
player_sharpen = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\player_sharpen.sqf";
player_butcher = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\gather_meat.sqf";
player_pushPlane = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\player_pushPlane.sqf";
//player_fixHatchet = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\player_fixTools.sqf";
//player_repairVehicle = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\repair_vehicle.sqf";
//player_salvageVehicle = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\salvage_vehicle.sqf";
//player_makeFire = compile preprocessFileLineNumbers "\z\addons\dayz_code\actions\player_makefire.sqf";

View File

@@ -25275,6 +25275,22 @@
<English>Broken APSI (Anti PSI) device, that must be repaired.</English>
<German>Kaputter APSI (Anti PSI) Emitter, welcher repariert werden muss.</German>
</Key>
<Key ID="STR_EQUIP_BROKEN_BINOCULAR">
<English>Broken Binocular</English>
<German>Kaputtes Fernglas</German>
</Key>
<Key ID="STR_EQUIP_BROKEN_BINOCULAR_DESC">
<English>Broken Binocular that must be repaired.</English>
<German>Ein kaputtes Fernglas, welches repariert werden muss.</German>
</Key>
<Key ID="STR_EQUIP_BROKEN_BINOCULARVECTOR">
<English>Broken Rangefinder</English>
<German>Kaputter Entfernungsmesser</German>
</Key>
<Key ID="STR_EQUIP_BROKEN_BINOCULARVECTOR_DESC">
<English>Broken Rangefinder that must be repaired.</English>
<German>Ein kaputter Entfernungsmesser, welcher repariert werden muss.</German>
</Key>
<Key ID="STR_EPOCH_SNAP_TUTORIAL_DISABLE">
<English>Disabled:</English>
<German>Deaktiviert:</German>
@@ -25493,6 +25509,38 @@
<English>%1 or %2</English>
<German>%1 oder %2</German>
</Key>
<Key ID="STR_ACTIONS_FIX_SHOVEL">
<English>Fix Shovel</English>
<German>Schaufel reparieren</German>
</Key>
<Key ID="STR_ACTIONS_FIX_CROWBAR">
<English>Fix Crowbar</English>
<German>Brechstange reparieren</German>
</Key>
<Key ID="STR_ACTIONS_FIX_ETOOL">
<English>Fix Entrenching Tool</English>
<German>Klappspaten reparieren</German>
</Key>
<Key ID="STR_ACTIONS_FIX_FISHINGPOLE">
<English>Fix Fishing Pole</English>
<German>Angel reparieren</German>
</Key>
<Key ID="STR_ACTIONS_FIX_NIGHTVISION">
<English>Fix Nightvision</English>
<German>Nachtsichtgerät reparieren</German>
</Key>
<Key ID="STR_ACTIONS_FIX_BIONCULARVECTOR">
<English>Fix Rangefinder</English>
<German>Entfernungsmesser reparieren</German>
</Key>
<Key ID="STR_ACTIONS_FIX_RADIO">
<English>Fix Radio</English>
<German>Funkgerät reparieren</German>
</Key>
<Key ID="STR_ACTIONS_FIX_GPS">
<English>Fix GPS</English>
<German>GPS reparieren</German>
</Key>
<!--Fix for missing strings from the buildings3.pbo, this is just a placeholder-->
<Key ID="STR_FAL_Street_Sign">