From 56de9e29e16457a6733436225fbdd456e7bdf3f2 Mon Sep 17 00:00:00 2001 From: FyloZ Date: Sun, 19 Jul 2020 19:05:58 -0400 Subject: [PATCH] Added new axes. --- Content/Decimation.cs | 32 ++++++++++++--- Content/DecimationRecipeGroupID.cs | 11 ++++++ Content/Items/Tools/Axes/BorealWoodAxe.cs | 33 ++++++++++++++++ Content/Items/Tools/Axes/BorealWoodAxe.png | Bin 0 -> 337 bytes Content/Items/Tools/Axes/CactusAxe.cs | 33 ++++++++++++++++ Content/Items/Tools/Axes/CactusAxe.png | Bin 0 -> 445 bytes Content/Items/Tools/Axes/EbonwoodAxe.cs | 33 ++++++++++++++++ Content/Items/Tools/Axes/EbonwoodAxe.png | Bin 0 -> 337 bytes Content/Items/Tools/Axes/GreatwoodAxe.cs | 37 ++++++++++++++++++ Content/Items/Tools/Axes/GreatwoodAxe.png | Bin 0 -> 482 bytes Content/Items/Tools/Axes/MultigrainAxe.cs | 39 +++++++++++++++++++ Content/Items/Tools/Axes/MultigrainAxe.png | Bin 0 -> 654 bytes Content/Items/Tools/Axes/PalmWoodAxe.cs | 33 ++++++++++++++++ Content/Items/Tools/Axes/PalmWoodAxe.png | Bin 0 -> 337 bytes Content/Items/Tools/Axes/PearlwoodAxe.cs | 33 ++++++++++++++++ Content/Items/Tools/Axes/PearlwoodAxe.png | Bin 0 -> 336 bytes Content/Items/Tools/Axes/PumpkinAxe.cs | 33 ++++++++++++++++ Content/Items/Tools/Axes/PumpkinAxe.png | Bin 0 -> 438 bytes Content/Items/Tools/Axes/RichMahoganyAxe.cs | 33 ++++++++++++++++ Content/Items/Tools/Axes/RichMahoganyAxe.png | Bin 0 -> 337 bytes Content/Items/Tools/Axes/ShadewoodAxe.cs | 33 ++++++++++++++++ Content/Items/Tools/Axes/ShadewoodAxe.png | Bin 0 -> 333 bytes Lib/Items/DecimationTool.cs | 17 ++++---- Lib/Util/Builder/RecipeBuilder.cs | 11 ++++++ 24 files changed, 398 insertions(+), 13 deletions(-) create mode 100644 Content/DecimationRecipeGroupID.cs create mode 100644 Content/Items/Tools/Axes/BorealWoodAxe.cs create mode 100644 Content/Items/Tools/Axes/BorealWoodAxe.png create mode 100644 Content/Items/Tools/Axes/CactusAxe.cs create mode 100644 Content/Items/Tools/Axes/CactusAxe.png create mode 100644 Content/Items/Tools/Axes/EbonwoodAxe.cs create mode 100644 Content/Items/Tools/Axes/EbonwoodAxe.png create mode 100644 Content/Items/Tools/Axes/GreatwoodAxe.cs create mode 100644 Content/Items/Tools/Axes/GreatwoodAxe.png create mode 100644 Content/Items/Tools/Axes/MultigrainAxe.cs create mode 100644 Content/Items/Tools/Axes/MultigrainAxe.png create mode 100644 Content/Items/Tools/Axes/PalmWoodAxe.cs create mode 100644 Content/Items/Tools/Axes/PalmWoodAxe.png create mode 100644 Content/Items/Tools/Axes/PearlwoodAxe.cs create mode 100644 Content/Items/Tools/Axes/PearlwoodAxe.png create mode 100644 Content/Items/Tools/Axes/PumpkinAxe.cs create mode 100644 Content/Items/Tools/Axes/PumpkinAxe.png create mode 100644 Content/Items/Tools/Axes/RichMahoganyAxe.cs create mode 100644 Content/Items/Tools/Axes/RichMahoganyAxe.png create mode 100644 Content/Items/Tools/Axes/ShadewoodAxe.cs create mode 100644 Content/Items/Tools/Axes/ShadewoodAxe.png diff --git a/Content/Decimation.cs b/Content/Decimation.cs index 941ec04..37c86ed 100644 --- a/Content/Decimation.cs +++ b/Content/Decimation.cs @@ -1,6 +1,7 @@ using System; using System.Collections.Generic; using System.IO; +using Decimation.Content.Items.Tools.Axes; using Decimation.Content.NPCs.Arachnus; using Decimation.Content.NPCs.DuneWyrm; using Decimation.Content.NPCs.DuneWyrm.AncientTombCrawler; @@ -9,6 +10,7 @@ using Decimation.Lib.Util; using Microsoft.Xna.Framework; using Terraria; using Terraria.ID; +using Terraria.Localization; using Terraria.ModLoader; using Terraria.UI; @@ -105,14 +107,32 @@ namespace Decimation.Content public override void AddRecipeGroups() { - RecipeGroup gems = new RecipeGroup(() => Lang.misc[37] + " Gem", ItemID.Amethyst, ItemID.Topaz, - ItemID.Emerald, ItemID.Sapphire, ItemID.Ruby, ItemID.Diamond); + RecipeGroup gems = new RecipeGroup(() => Language.GetTextValue("LegacyMisc.37") + " Gem", + ItemID.Amethyst, + ItemID.Topaz, + ItemID.Emerald, + ItemID.Sapphire, + ItemID.Ruby, + ItemID.Diamond); + RecipeGroup.RegisterGroup(DecimationRecipeGroupID.AnyGem, gems); - RecipeGroup threads = new RecipeGroup(() => Lang.misc[37] + " Thread", ItemID.BlackThread, - ItemID.GreenThread, ItemID.PinkThread); + RecipeGroup threads = new RecipeGroup(() => Language.GetTextValue("LegacyMisc.37") + " Thread", + ItemID.BlackThread, + ItemID.GreenThread, + ItemID.PinkThread); + RecipeGroup.RegisterGroup(DecimationRecipeGroupID.AnyThread, threads); - RecipeGroup.RegisterGroup("AnyGem", gems); - RecipeGroup.RegisterGroup("AnyThread", threads); + RecipeGroup corruptedWoodAxes = new RecipeGroup( + () => Language.GetTextValue("LegacyMisc.37") + " Corrupted Wood Axe", + ModContent.ItemType(), + ModContent.ItemType()); + RecipeGroup.RegisterGroup(DecimationRecipeGroupID.CorruptedWoodAxes, corruptedWoodAxes); + + RecipeGroup corruptedWoodHammers = new RecipeGroup( + () => Language.GetTextValue("LegacyMisc.37") + " Corrupted Wood Hammer", + ItemID.ShadewoodHammer, + ItemID.EbonwoodHammer); + RecipeGroup.RegisterGroup(DecimationRecipeGroupID.CorruptedWoodHammers, corruptedWoodHammers); } public override void HandlePacket(BinaryReader reader, int whoAmI) diff --git a/Content/DecimationRecipeGroupID.cs b/Content/DecimationRecipeGroupID.cs new file mode 100644 index 0000000..ec58c84 --- /dev/null +++ b/Content/DecimationRecipeGroupID.cs @@ -0,0 +1,11 @@ +namespace Decimation.Content +{ + public class DecimationRecipeGroupID + { + public const string AnyGem = "AnyGem"; + public const string AnyThread = "AnyThread"; + public const string CorruptedWoodAxes = "CorruptedAxes"; + public const string CorruptedWoodHammers = "CorruptedHammers"; + public const string CorruptedWoodPickaxes = "CorruptedPickaxes"; + } +} \ No newline at end of file diff --git a/Content/Items/Tools/Axes/BorealWoodAxe.cs b/Content/Items/Tools/Axes/BorealWoodAxe.cs new file mode 100644 index 0000000..c0d7275 --- /dev/null +++ b/Content/Items/Tools/Axes/BorealWoodAxe.cs @@ -0,0 +1,33 @@ +using Decimation.Lib.Items; +using Decimation.Lib.Util.Builder; +using Terraria; +using Terraria.ID; +using Terraria.ModLoader; + +namespace Decimation.Content.Items.Tools.Axes +{ + public class BorealWoodAxe : DecimationTool + { + protected override string ItemName => "Boreal Wood Axe"; + protected override int AxePower => 35; + protected override int MeleeDamages => 3; + + protected override void InitTool() + { + item.width = 32; + item.height = 28; + item.knockBack = 4.5f; + item.value = Item.sellPrice(copper: 10); + item.useTime = 19; + item.useAnimation = 28; + item.crit = 4; + } + + protected override ModRecipe GetRecipe() + { + return new RecipeBuilder(this) + .WithIngredient(ItemID.BorealWood, 7) + .Build(); + } + } +} \ No newline at end of file diff --git a/Content/Items/Tools/Axes/BorealWoodAxe.png b/Content/Items/Tools/Axes/BorealWoodAxe.png new file mode 100644 index 0000000000000000000000000000000000000000..dc82e84b200d066dda353dba23d0a51d3a55e7db GIT binary patch literal 337 zcmeAS@N?(olHy`uVBq!ia0vp^3P3Ew!3HE54((L}l8nVc?oJHr&dIz4a#+$GeH|GX zHuiJ>Nn{1`ISV`@iy0XB4ude`@%$AjK*498E{-7{-pMHo1WtH${A)Kl_~2vrb&a$` zPc9x!Y~b|bmr$@~NwC{|A&~L&(UuTJ+Qib{sEJ! z4xarc49qVS6SEdDFY}Mz!L%%~u%9nM(Wu6WfvupGMaTEV>648wPkNg*yj(b+yC|9I zK+TN)1P0sk0|zefGtM~w_f5}%nlCkddi=~U?BuIs|1GWzYfYX9r-0A zd*I7K2EDJ%<}4S2jTc7s#u)r?YKXIIZ#*c>WH4Vi>u{hnPYnmpl=F!RA6giAE}VXD gU~oY3zySsZxyb6hD_ToF1AWZk>FVdQ&MBb@04;xmH~;_u literal 0 HcmV?d00001 diff --git a/Content/Items/Tools/Axes/CactusAxe.cs b/Content/Items/Tools/Axes/CactusAxe.cs new file mode 100644 index 0000000..991afcf --- /dev/null +++ b/Content/Items/Tools/Axes/CactusAxe.cs @@ -0,0 +1,33 @@ +using Decimation.Lib.Items; +using Decimation.Lib.Util.Builder; +using Terraria; +using Terraria.ID; +using Terraria.ModLoader; + +namespace Decimation.Content.Items.Tools.Axes +{ + public class CactusAxe : DecimationTool + { + protected override string ItemName => "Cactus Axe"; + protected override int AxePower => 35; + protected override int MeleeDamages => 3; + + protected override void InitTool() + { + item.width = 44; + item.height = 34; + item.knockBack = 4.5f; + item.value = Item.sellPrice(copper: 30); + item.useTime = 23; + item.useAnimation = 32; + item.crit = 4; + } + + protected override ModRecipe GetRecipe() + { + return new RecipeBuilder(this) + .WithIngredient(ItemID.Cactus, 15) + .Build(); + } + } +} \ No newline at end of file diff --git a/Content/Items/Tools/Axes/CactusAxe.png b/Content/Items/Tools/Axes/CactusAxe.png new file mode 100644 index 0000000000000000000000000000000000000000..5b8ec2f213e35bc4b6398b6b37635aacbbc0a819 GIT binary patch literal 445 zcmV;u0Yd(XP)Px#1ZP1_K>z@;j|==^1poj532;bRa{vGi!vFvd!vV){sAK>D0a8gsK~z{r?Uu1> z!cY{3Q$ZJ<3W7L@Z{T2Ya&qV{2!*blI*ZUpD2TIDSD}-8=T2e=-#{FSQ0UYyEmZN) zPv}oC5t1P{$v5QpLhcd1oO_b9AR?7cYxn!}Up^MANdG~7>J$zapNP%y!{p1>@V5Q7 zyc?G-l`!+vy&rwrnmXAt3@#&={f#ADb!(P4!;+=TbZ!{*6tli)uMctL_PTEQ_`J1z znl~)fuSSr~ytfyIf z6NA&)tL5^gX$d-?6^!SG)v)#=X2a&K!u+k)ik8_m?CM3=n@myDF0<50zhO0^rypEq z*$=0hh4dQMo;|fkf&F~nVp4ILh4dMYYF5!6R>JD0$8g+c "Ebonwood Axe"; + protected override int AxePower => 40; + protected override int MeleeDamages => 6; + + protected override void InitTool() + { + item.width = 32; + item.height = 28; + item.knockBack = 4.5f; + item.value = Item.sellPrice(copper: 10); + item.useTime = 16; + item.useAnimation = 25; + item.crit = 4; + } + + protected override ModRecipe GetRecipe() + { + return new RecipeBuilder(this) + .WithIngredient(ItemID.Ebonwood, 7) + .Build(); + } + } +} \ No newline at end of file diff --git a/Content/Items/Tools/Axes/EbonwoodAxe.png b/Content/Items/Tools/Axes/EbonwoodAxe.png new file mode 100644 index 0000000000000000000000000000000000000000..99d34185948812753ce60bf2007e031ccd2eb85a GIT binary patch literal 337 zcmeAS@N?(olHy`uVBq!ia0vp^3P3Ew!3HE54((L}l8nVc?oJHr&dIz4a#+$GeH|GX zHuiJ>Nn{1`ISV`@iy0XB4ude`@%$AjK*498E{-7{-pMHo1WugJ`qyrB@WI2!uQk#R zJ-K)^v4PWzUqZo}CBe?va2wlaSJx#6zI>az`k)EVfhXtZ*m5nq=$!PU^}uWM^9M|- zI(YV*FfhMRT)1=<@3QrG_i-&tEbQk?P&BG>Vqhz1Wzq5N;Nog}>8hR9_;TTV?ng?O z4%E!(PhhYuKXBjzKjVz^ws)Nm)_key)8l7;VJBa;lOcT0;^_r1UL`P0|8-EF>Buh` z*#ln=GU$D6HfOmIY`ie4H^$(HQ$w6xd*eZ2CWHCHS%(9qd1^R#rkqbq_|U?@bK&%J e1A_yK2M#bW#4fD "Greatwood Axe"; + protected override int AxePower => 50; + protected override int MeleeDamages => 6; + + protected override void InitTool() + { + item.width = 48; + item.height = 36; + item.knockBack = 4.5f; + item.value = Item.sellPrice(copper: 40); + item.useTime = 20; + item.useAnimation = 28; + item.crit = 4; + } + + protected override ModRecipe GetRecipe() + { + return new RecipeBuilder(this) + .WithIngredient(ModContent.ItemType()) + .WithIngredient(ModContent.ItemType()) + .WithIngredient(ModContent.ItemType()) + .WithIngredientGroup(DecimationRecipeGroupID.CorruptedWoodAxes) + .WithStation(TileID.WorkBenches) + .Build(); + } + } +} \ No newline at end of file diff --git a/Content/Items/Tools/Axes/GreatwoodAxe.png b/Content/Items/Tools/Axes/GreatwoodAxe.png new file mode 100644 index 0000000000000000000000000000000000000000..10a0bd51901009241e5f2ff88544a4e186b15a50 GIT binary patch literal 482 zcmV<80UiE{P)Px#1ZP1_K>z@;j|==^1poj532;bRa{vGi!vFvd!vV){sAK>D0e4A6K~z{r?U=Dj z13?r;SARgz$~1yT5$s}-LP%$6Yn|3V@Du!lwAQvM?E)4lv=c<5VB=Pb`2vMUPLYd` zF}s7ZlR3@HkYxw%*?Di-l_C<|z0I%L&pF1AWwbqhVs%y{^IP^)(?}3)u*?2 zt2g(rR@Hae~ zQzyNyRg&la%V*%X$%pXH5HKHfqA#z3SjmGL0PkH&lZW&TX!0Zhi$3$-d;6qo zz)QaFv##C7OB_P`rDq^k@`|1Tk45)M#{db%`eOE1G~a-BiK>(JzevXbG$naxxPhYh Y26&VDfauAYp8x;=07*qoM6N<$f~Ke7%K!iX literal 0 HcmV?d00001 diff --git a/Content/Items/Tools/Axes/MultigrainAxe.cs b/Content/Items/Tools/Axes/MultigrainAxe.cs new file mode 100644 index 0000000..8207435 --- /dev/null +++ b/Content/Items/Tools/Axes/MultigrainAxe.cs @@ -0,0 +1,39 @@ +using Decimation.Lib.Items; +using Decimation.Lib.Util; +using Decimation.Lib.Util.Builder; +using Terraria; +using Terraria.ID; +using Terraria.ModLoader; + +namespace Decimation.Content.Items.Tools.Axes +{ + public class MultigrainAxe : DecimationTool + { + protected override string ItemName => "Multigrain Axe"; + protected override int AxePower => 60; + protected override int MeleeDamages => 10; + + protected override void InitTool() + { + item.width = 54; + item.height = 42; + item.knockBack = 5f; + item.value = Item.sellPrice(silver: 8, copper: 70); + item.rare = Rarity.Blue.GetRarityValue(); + item.useTime = 16; + item.useAnimation = 24; + item.crit = 4; + } + + protected override ModRecipe GetRecipe() + { + return new RecipeBuilder(this) + .WithIngredient(ModContent.ItemType()) + .WithIngredient(ModContent.ItemType()) + .WithIngredient(ModContent.ItemType()) + .WithIngredient(ItemID.Vine, 2) + .WithStation(TileID.Loom) + .Build(); + } + } +} \ No newline at end of file diff --git a/Content/Items/Tools/Axes/MultigrainAxe.png b/Content/Items/Tools/Axes/MultigrainAxe.png new file mode 100644 index 0000000000000000000000000000000000000000..cb35074671b5d4fb9c6690d5b2d735202b100888 GIT binary patch literal 654 zcmV;90&)F`P)Px#1ZP1_K>z@;j|==^1poj532;bRa{vGi!vFvd!vV){sAK>D0wYO8K~!i%?U+j_ zL}3_)$2FIQ(A2m@xh`f$v2aObDHdWSWMgS%!NNi;EMzGgq!cSn+*~q_|BHCE6(Aad_D{6K@!ZX*>{f3baM&QI7m*I6^vI>McSWvkHxIy5~&T zzw&dU;O`` "Palm Wood Axe"; + protected override int AxePower => 35; + protected override int MeleeDamages => 3; + + protected override void InitTool() + { + item.width = 32; + item.height = 28; + item.knockBack = 4.5f; + item.value = Item.sellPrice(copper: 10); + item.useTime = 19; + item.useAnimation = 28; + item.crit = 4; + } + + protected override ModRecipe GetRecipe() + { + return new RecipeBuilder(this) + .WithIngredient(ItemID.PalmWood, 7) + .Build(); + } + } +} \ No newline at end of file diff --git a/Content/Items/Tools/Axes/PalmWoodAxe.png b/Content/Items/Tools/Axes/PalmWoodAxe.png new file mode 100644 index 0000000000000000000000000000000000000000..7f0bafeeb9ae03713d463ffae54b84b14ecb6ea7 GIT binary patch literal 337 zcmeAS@N?(olHy`uVBq!ia0vp^3P3Ew!3HE54((L}l8nVc?oJHr&dIz4a#+$GeH|GX zHuiJ>Nn{1`ISV`@iy0XB4ude`@%$AjK*498E{-7{-pMHo1YT&I{L^l9@WH9Q>KbW> zo?JYd*ud$*)MO{;m*E6K+;Z;fq91$(=;`fl-2_!QAfoLY`+vAT*D`C zApcBR!r{EEfx#DNhG(DG "Pearlwood Axe"; + protected override int AxePower => 45; + protected override int MeleeDamages => 8; + + protected override void InitTool() + { + item.width = 32; + item.height = 28; + item.knockBack = 4.5f; + item.value = Item.sellPrice(copper: 10); + item.useTime = 16; + item.useAnimation = 25; + item.crit = 4; + } + + protected override ModRecipe GetRecipe() + { + return new RecipeBuilder(this) + .WithIngredient(ItemID.Pearlwood, 7) + .Build(); + } + } +} \ No newline at end of file diff --git a/Content/Items/Tools/Axes/PearlwoodAxe.png b/Content/Items/Tools/Axes/PearlwoodAxe.png new file mode 100644 index 0000000000000000000000000000000000000000..7bfa6ad9b1e0facb043e83ddcdca4133d322932c GIT binary patch literal 336 zcmeAS@N?(olHy`uVBq!ia0vp^3P3Ew!3HE54((L}l8nVc?oJHr&dIz4a#+$GeH|GX zHuiJ>Nn{1`ISV`@iy0XB4ude`@%$AjK*6V;E{-7{-pMHo1YWE-{jc5V;Db|Vk87kI zdUEk-Vgsiazl4G{OM+cD&j#ktp;J{4mIS}|GT>!4`1w?tuQBt>1c^Gug5U3o4SMC2 z4(szCV5stlhV{_*@xVXfdOI-ua796B+J4ch(nw&{h0Jh%Z)_=RuJD59fx6`HPun z*hw5%TKA!ip(;x)Wc5UDws?*Ur=J@bR5&p_D|X7Y$ZBrnZ*2Tz$-^@bXld0?88$Wx c76}Q4SubihlN5L#06om$>FVdQ&MBb@09Vv_8vp "Pumpkin Axe"; + protected override int AxePower => 35; + protected override int MeleeDamages => 5; + + protected override void InitTool() + { + item.width = 40; + item.height = 32; + item.knockBack = 4.5f; + item.value = Item.sellPrice(silver: 4); + item.useTime = 23; + item.useAnimation = 32; + item.crit = 4; + } + + protected override ModRecipe GetRecipe() + { + return new RecipeBuilder(this) + .WithIngredient(ItemID.Pumpkin, 15) + .Build(); + } + } +} \ No newline at end of file diff --git a/Content/Items/Tools/Axes/PumpkinAxe.png b/Content/Items/Tools/Axes/PumpkinAxe.png new file mode 100644 index 0000000000000000000000000000000000000000..1a8dc9a941818d7f335d617a46cf712547134565 GIT binary patch literal 438 zcmV;n0ZIOeP)Px#1ZP1_K>z@;j|==^1poj532;bRa{vGi!vFvd!vV){sAK>D0ZU0lK~z{r<(4r^ z!$25@W0y)D3f;417es1Z1b0CYadB2~5TX8#7Q{i&*-Zq&U2xJOf_t{^-730R@wLz3 z2S*B5@Gg0lH%F2SdGh7ETS(@_PS%)A5C3qRzk5BSHqBu1Hi)^i&6dWsl~nolI#ixK zjFgsH%~r?Y`RTI8@N}0eJKLFZebQ8}_8*llgSM8dSA&D$rxJ6E*_!ere^ws%-jvp$ z{SsVPeuIF4{cK5N3<5RTPU}kkZcK9j)y3gYBnL;A%IX=kwFuTIHD;-vLCn2$H#DZt zLD34sd1&nID$8#WbA$WeH*Rm;C|&){Qq(ugYY-#0;}`8txQ{*wE_2LR9)rH-z^*hd za}d8lUvst(f?Y{m^Tlh>8nC;MB5dthW}PQKgTChGO*{rMN1wXR$IAaQ2jLqG)f~iQ g5JE8rfg4PcZ$I3xE7}E5HUIzs07*qoM6N<$f(4nqTL1t6 literal 0 HcmV?d00001 diff --git a/Content/Items/Tools/Axes/RichMahoganyAxe.cs b/Content/Items/Tools/Axes/RichMahoganyAxe.cs new file mode 100644 index 0000000..3e21fdd --- /dev/null +++ b/Content/Items/Tools/Axes/RichMahoganyAxe.cs @@ -0,0 +1,33 @@ +using Decimation.Lib.Items; +using Decimation.Lib.Util.Builder; +using Terraria; +using Terraria.ID; +using Terraria.ModLoader; + +namespace Decimation.Content.Items.Tools.Axes +{ + public class RichMahoganyAxe : DecimationTool + { + protected override string ItemName => "Rich Mahogany Axe"; + protected override int AxePower => 35; + protected override int MeleeDamages => 3; + + protected override void InitTool() + { + item.width = 32; + item.height = 28; + item.knockBack = 4.5f; + item.value = Item.sellPrice(copper: 20); + item.useTime = 19; + item.useAnimation = 28; + item.crit = 4; + } + + protected override ModRecipe GetRecipe() + { + return new RecipeBuilder(this) + .WithIngredient(ItemID.RichMahogany, 7) + .Build(); + } + } +} \ No newline at end of file diff --git a/Content/Items/Tools/Axes/RichMahoganyAxe.png b/Content/Items/Tools/Axes/RichMahoganyAxe.png new file mode 100644 index 0000000000000000000000000000000000000000..5de833ac1cc6039de7171bc15aab1f47a44f946b GIT binary patch literal 337 zcmeAS@N?(olHy`uVBq!ia0vp^3P3Ew!3HE54((L}l8nVc?oJHr&dIz4a#+$GeH|GX zHuiJ>Nn{1`ISV`@iy0XB4ude`@%$AjK*498E{-7{-pMHo1SC8?{K=)%8Hh)kT#FRWF`5ZQG$@ zApcBR!r{EEfx#DNhG(Ch^6d@eZRamOeVAd_`Sv)y1ESAgsLJfJk~pxm?n67nMmu+Q zgIa?I@4pXt8NXcdSrMiz&a+Qo!SwTq2_IS*&OC3qRd9ukS)PgcX|aTa4bajrpDcNJ e3OEc57#QNJt3NJ(TXqHLV+K!GKbLh*2~7Zp^?XnO literal 0 HcmV?d00001 diff --git a/Content/Items/Tools/Axes/ShadewoodAxe.cs b/Content/Items/Tools/Axes/ShadewoodAxe.cs new file mode 100644 index 0000000..648bfea --- /dev/null +++ b/Content/Items/Tools/Axes/ShadewoodAxe.cs @@ -0,0 +1,33 @@ +using Decimation.Lib.Items; +using Decimation.Lib.Util.Builder; +using Terraria; +using Terraria.ID; +using Terraria.ModLoader; + +namespace Decimation.Content.Items.Tools.Axes +{ + public class ShadewoodAxe : DecimationTool + { + protected override string ItemName => "Shadewood Axe"; + protected override int AxePower => 40; + protected override int MeleeDamages => 6; + + protected override void InitTool() + { + item.width = 32; + item.height = 28; + item.knockBack = 4.5f; + item.value = Item.sellPrice(copper: 10); + item.useTime = 16; + item.useAnimation = 25; + item.crit = 4; + } + + protected override ModRecipe GetRecipe() + { + return new RecipeBuilder(this) + .WithIngredient(ItemID.Shadewood, 7) + .Build(); + } + } +} \ No newline at end of file diff --git a/Content/Items/Tools/Axes/ShadewoodAxe.png b/Content/Items/Tools/Axes/ShadewoodAxe.png new file mode 100644 index 0000000000000000000000000000000000000000..38aa7f1e4102c8199f40ad6ed6469986b3a7b98c GIT binary patch literal 333 zcmeAS@N?(olHy`uVBq!ia0vp^3P3Ew!3HE54((L}l8nVc?oJHr&dIz4a#+$GeH|GX zHuiJ>Nn{1`ISV`@iy0XB4ude`@%$AjK*2|zE{-7{-gl?%<~?M<;KJ)IkrBbb`9dR+ z`IU~tT+g7*4q0XmllUe?G_Y-A^>APJKt)?)!H>_g4&QLxC2qYiy)MOIp3Uq21-oMH z>n4BxW&85_%ie2jH*z*c?K^&0uqb?*$DyB(|22dNzm!}dSH48bGoN3;)Nt%kp d8)<`Qtf8LO?}JQqyMVrB@O1TaS?83{1OTxVg>wJ^ literal 0 HcmV?d00001 diff --git a/Lib/Items/DecimationTool.cs b/Lib/Items/DecimationTool.cs index 2fbe11d..1ecd54d 100644 --- a/Lib/Items/DecimationTool.cs +++ b/Lib/Items/DecimationTool.cs @@ -12,17 +12,20 @@ protected override void Init() { item.autoReuse = true; - this.item.useTurn = true; - this.item.maxStack = 1; + item.useStyle = 1; + item.useTurn = true; + item.maxStack = 1; + item.melee = true; InitTool(); - this.item.damage = this.MeleeDamages; - this.item.pick = this.PickaxePower; - this.item.axe = this.AxePower; - this.item.hammer = this.HammerPower; + item.damage = MeleeDamages; + item.pick = PickaxePower; + item.axe = AxePower / 5; // Axe power is multiplied by 5 for some reason + item.hammer = HammerPower; - if (this.MeleeDamages > 0) this.item.melee = true; + item.damage = 1000; + if (MeleeDamages > 0) item.noMelee = false; } } } \ No newline at end of file diff --git a/Lib/Util/Builder/RecipeBuilder.cs b/Lib/Util/Builder/RecipeBuilder.cs index 810e937..2d30e81 100644 --- a/Lib/Util/Builder/RecipeBuilder.cs +++ b/Lib/Util/Builder/RecipeBuilder.cs @@ -6,6 +6,7 @@ namespace Decimation.Lib.Util.Builder internal class RecipeBuilder { private readonly IDictionary _ingredients = new Dictionary(); + private readonly IDictionary _ingredientGroups = new Dictionary(); private readonly Mod _mod; private readonly int _result; private readonly int _resultQuantity; @@ -31,6 +32,13 @@ namespace Decimation.Lib.Util.Builder return this; } + public RecipeBuilder WithIngredientGroup(string group, int quantity = 1) + { + _ingredientGroups.Add(group, quantity); + + return this; + } + public RecipeBuilder WithStation(int tile) { _tiles.Add(tile); @@ -51,6 +59,9 @@ namespace Decimation.Lib.Util.Builder foreach (KeyValuePair ingredient in _ingredients) recipe.AddIngredient(ingredient.Key, ingredient.Value); + + foreach (KeyValuePair ingredientGroup in _ingredientGroups) + recipe.AddRecipeGroup(ingredientGroup.Key, ingredientGroup.Value); foreach (int tile in _tiles) recipe.AddTile(tile);