diff --git a/.vs/NekoTweakMod/DesignTimeBuild/.dtbcache.v2 b/.vs/NekoTweakMod/DesignTimeBuild/.dtbcache.v2 index 117469c..6c078e6 100644 Binary files a/.vs/NekoTweakMod/DesignTimeBuild/.dtbcache.v2 and b/.vs/NekoTweakMod/DesignTimeBuild/.dtbcache.v2 differ diff --git a/.vs/NekoTweakMod/v16/.suo b/.vs/NekoTweakMod/v16/.suo index b917ff6..d2eedca 100644 Binary files a/.vs/NekoTweakMod/v16/.suo and b/.vs/NekoTweakMod/v16/.suo differ diff --git a/Items/AddTooltip.cs b/Items/AddTooltip.cs index b90d037..313e7ef 100644 --- a/Items/AddTooltip.cs +++ b/Items/AddTooltip.cs @@ -9,13 +9,13 @@ public class AddTooltip : GlobalItem { public override void ModifyTooltips(Item item, List tooltips) // Allows you to modify tooltip properties for items { - if (item.type == ItemID.Shackle) // Specifies what item + if (item.type == ItemID.Shackle) // Specifies what item { TooltipLine newTooltip = new TooltipLine(mod, "Tooltip0", "Enemies are more likely to target you"); // Creates a new TooltipLine for your mod with the name Tooltip0 - //"Tooltip#" - A tooltip line of the item. # will be 0 for the first line, 1 for the second, etc. + // "Tooltip#" - A tooltip line of the item. # will be 0 for the first line, 1 for the second, etc. tooltips.Add(newTooltip); - //Adds the Tooltip to the list + // Adds the Tooltip to the list } { if (item.type == ItemID.TitanGlove) diff --git a/Items/Fishing/AddItemToCrate.cs b/Items/Fishing/AddItemToCrate.cs new file mode 100644 index 0000000..ca8dbf5 --- /dev/null +++ b/Items/Fishing/AddItemToCrate.cs @@ -0,0 +1,37 @@ +using Terraria.ID; +using Terraria; +using Terraria.ModLoader; + +namespace NekoTweakMod.Items.Fishing +{ + public class AddItemToCrate : GlobalItem + { + public string Context; + public bool RandomBool; // still no idea how either string or bool works here, but got errors without using InstancePerEntity & code works fine + + public override bool InstancePerEntity => true; + + public override GlobalItem Clone(Item item, Item itemClone) + { + AddItemToCrate myClone = (AddItemToCrate)base.Clone(item, itemClone); + myClone.Context = Context; + myClone.RandomBool = RandomBool; + return myClone; + } + public override void OpenVanillaBag(string context, Player player, int arg) + { + if (context == "crate" && arg == ItemID.IronCrate) + // if context & arg is = text & item id + // Context has to be one of these examples: "present", "bossBag", "crate", "lockBox", "herbBag", or "goodieBag" + // arg specifies the present/bag/crate itemid + { + // Each item here will roll individually, but it is possible to get multiple of them at once + if (Main.rand.NextBool(33)) player.QuickSpawnItem(ItemID.WoodenSword); // number/100 or "100% if its at 1" chance/rng & also Specifies the item to add to the present/bag/crate + // if (Main.rand.NextBool(25)) player.QuickSpawnItem(ItemID.Meowmere); + // if (Main.rand.NextBool(50)) player.QuickSpawnItem(ItemID.PlanteraBossBag); + // if (Main.rand.NextBool(75)) player.QuickSpawnItem(ItemID.HotlineFishingHook); + + } + } + } +} \ No newline at end of file diff --git a/Items/Fishing/FishingRods.cs b/Items/Fishing/FishingRods.cs new file mode 100644 index 0000000..845dee7 --- /dev/null +++ b/Items/Fishing/FishingRods.cs @@ -0,0 +1,24 @@ +using Terraria.ID; +using Terraria; +using Terraria.ModLoader; + +namespace NekoTweakMod.Items +{ + public class FishingRods : GlobalItem // class name & vanilla hook + { + public override void SetDefaults(Item item) // SetDefaults allows you to set/change properties of items + { // Single line "if" statements as we are only changing 1 property + if (item.type == ItemID.WoodFishingPole) item.fishingPole = 15; // sets fishing power to 15% + if (item.type == ItemID.ReinforcedFishingPole) item.fishingPole = 20; + //if (item.type == ItemID.ScarabFishingRod) item.fishingPole = 30; + //if (item.type == ItemID.ChumCaster) item.fishingPole = 30; + if (item.type == ItemID.FiberglassFishingPole) item.fishingPole = 30; + if (item.type == ItemID.SittingDucksFishingRod) item.fishingPole = 33; + if (item.type == ItemID.FisherofSouls) item.fishingPole = 35; + if (item.type == ItemID.Fleshcatcher) item.fishingPole = 37; + if (item.type == ItemID.MechanicsRod) item.fishingPole = 45; + if (item.type == ItemID.HotlineFishingHook) item.fishingPole = 47; + + } + } +} \ No newline at end of file diff --git a/Items/ModifyAccessories.cs b/Items/ModifyAccessories.cs new file mode 100644 index 0000000..07716ad --- /dev/null +++ b/Items/ModifyAccessories.cs @@ -0,0 +1,49 @@ +using Terraria.ID; +using Terraria; +using Terraria.ModLoader; + +namespace NekoTweakMod.Items +{ + public class ModifyAccessories : GlobalItem + { + public override void UpdateAccessory(Item item, Player player, bool hideVisual) + { + if (item.type == ItemID.FeralClaws) + { + player.meleeSpeed -= 0.12f; // Gives -12% melee speed + player.kbGlove = false; // Sets this item as a knockback glove + if (player.HeldItem.melee || player.HeldItem.summon) // if the player is holding/using either a melee or summoner weapon + // Thanks to Oli for telling me about player.helditem + { + player.releaseUseItem = true; // Makes the accessory give autoReuse/AutoSwing to the players item/weapon + } + + } + { + //single-line "if" statement examples, changing 1 property only for each statement + if (item.type == ItemID.TitanGlove) player.meleeSpeed += 0.12f; // 12% increased melee speed + if (item.type == ItemID.Shackle) player.aggro += 50; // increases players aggro by 50+ + } + { + if (item.type == ItemID.FireGauntlet) + { + player.meleeDamage += 0.02f;// 2% increase + player.meleeSpeed += 0.02f; + if (player.HeldItem.melee || player.HeldItem.summon) player.releaseUseItem = true; + } + } + { + if (item.type == ItemID.MechanicalGlove) + { + if (player.HeldItem.melee || player.HeldItem.summon) player.releaseUseItem = true; + } + } + { + if (item.type == ItemID.PowerGlove) + { + if (player.HeldItem.melee || player.HeldItem.summon) player.releaseUseItem = true; + } + } + } + } +} \ No newline at end of file diff --git a/Items/SetDefaultVanilla.cs b/Items/ModifyEquipment.cs similarity index 87% rename from Items/SetDefaultVanilla.cs rename to Items/ModifyEquipment.cs index abb3b6b..e8bbae9 100644 --- a/Items/SetDefaultVanilla.cs +++ b/Items/ModifyEquipment.cs @@ -4,7 +4,7 @@ namespace NekoTweakMod.Items { - public class SetDefaultVanilla : GlobalItem // class name & vanilla hook + public class ModifyEquipment : GlobalItem // class name & vanilla hook { public override void SetDefaults(Item item) // SetDefaults allows you to set/change properties of items { @@ -15,7 +15,9 @@ public class SetDefaultVanilla : GlobalItem // class name & vanilla hook //item.knockBack = 0; } if (item.type == ItemID.WormScarf) item.defense = 2; // Single line if statement as we are only changing 1 property - if (item.type == ItemID.Muramasa) item.damage = 26; + if (item.type == ItemID.Muramasa) item.damage = 26; + if (item.type == ItemID.MiningShirt) item.shopCustomPrice = 40000; // changes the sale value + if (item.type == ItemID.MiningPants) item.shopCustomPrice = 40000; { if (item.type == ItemID.ReaverShark) { diff --git a/Items/ModifyTooltip.cs b/Items/ModifyTooltip.cs index a9f398c..1dd130a 100644 --- a/Items/ModifyTooltip.cs +++ b/Items/ModifyTooltip.cs @@ -29,14 +29,11 @@ public class ModifyTooltip : GlobalItem } } { - /* if(item.type == ItemID.PowerGlove) // Changing multiple tooltip lines at once - // Tooltip0 will be the first tooltip line & tooltip1 the second, etc - { - TooltipLine line2 = tooltips.FirstOrDefault(x => x.Name == "Tooltip0" && x.mod == "Terraria"); - if (line2 != null) line2.text = "powerglove knockback text"; - TooltipLine line3 = tooltips.FirstOrDefault(x => x.Name == "Tooltip1" && x.mod == "Terraria"); - if (line3 != null) line3.text = "12% increased melee speed"; - } */ + if (item.type == ItemID.FireGauntlet) + { + TooltipLine line2 = tooltips.FirstOrDefault(x => x.Name == "Tooltip1" && x.mod == "Terraria"); + if (line2 != null) line2.text = "12% increased melee damage and speed"; + } } } } diff --git a/Items/NoFakeChests.cs b/Items/NoFakeChests.cs new file mode 100644 index 0000000..d65c13d --- /dev/null +++ b/Items/NoFakeChests.cs @@ -0,0 +1,62 @@ +using Terraria.ID; +using Terraria; +using Terraria.ModLoader; + +namespace NekoTweakMod.Items +{ + public class NoFakeChests : GlobalItem + { + public override void SetDefaults(Item item) + { + } + } // still missing few 1.4 fake chests +} // hopefully this simple code change them to working chests~ +/* + if(item.type == ItemID.Fake_BlueDungeonChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_BoneChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_BorealWoodChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_CactusChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_Chest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_CorruptionChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_CrimsonChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_CrystalChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_DynastyChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_EbonwoodChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_FleshChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_FrozenChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_GlassChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_GoldChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_GoldenChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_GraniteChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_GreenDungeonChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_HallowedChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_HoneyChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_IceChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_IvyChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_JungleChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_LihzahrdChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_LivingWoodChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_MarbleChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_MartianChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_MeteoriteChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_MushroomChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_newchest1) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_newchest2) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_ObsidianChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_PalmWoodChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_PearlwoodChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_PinkDungeonChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_PumpkinChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_RichMahoganyChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_ShadewoodChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_ShadowChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_SkywareChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_SlimeChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_SpookyChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_SteampunkChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_WaterChest) item.CloneDefaults(ItemID.DeadMansChest); + if (item.type == ItemID.Fake_WebCoveredChest) item.CloneDefaults(ItemID.DeadMansChest); + } + } +} +*/ diff --git a/Items/SetNameOverride.cs b/Items/ReplaceItemName.cs similarity index 66% rename from Items/SetNameOverride.cs rename to Items/ReplaceItemName.cs index 44b1db8..9a4f165 100644 --- a/Items/SetNameOverride.cs +++ b/Items/ReplaceItemName.cs @@ -4,14 +4,13 @@ namespace NekoTweakMod.Items { - public class SetNameOverride : GlobalItem // class name & vanilla hook + public class ReplaceItemName : GlobalItem // class name & vanilla hook { public override void SetDefaults(Item item) // SetDefaults allows you to set/change properties of items { if (item.type == ItemID.IvyWhip) item.SetNameOverride("Ivy Hook"); // Ocd fix due to summoners having whip weapons // specifies what item to change - // Set the name of the specified item to "Name" - // seperation between each "if" statement when trying to change another item + // Set the name of the specified item to ("Name") } } } \ No newline at end of file diff --git a/Items/UpdateAccessories.cs b/Items/UpdateAccessories.cs deleted file mode 100644 index 760cba9..0000000 --- a/Items/UpdateAccessories.cs +++ /dev/null @@ -1,36 +0,0 @@ -using Terraria.ID; -using Terraria; -using Terraria.ModLoader; - -namespace NekoTweakMod.Items -{ - public class UpdateAccessories : GlobalItem - { - public override void UpdateAccessory(Item item, Player player, bool hideVisual) - { - if (item.type == ItemID.FeralClaws) - { - player.meleeSpeed -= 0.12f; // Gives -12% melee speed - player.kbGlove = false; // Sets this item as a knockback glove - player.releaseUseItem = true; // Gives the accessory autoReuse/AutoSwing - } - // if(item.noMelee) - // player.releaseUseItem = false; - { - //single-line "if" statement examples, changing 1 property only for each if statement - if (item.type == ItemID.TitanGlove) player.meleeSpeed += 0.12f; // 12% increased melee speed - if (item.type == ItemID.Shackle) player.aggro += 50; // increases players aggro by 50+ - if (item.type == ItemID.PowerGlove) player.releaseUseItem = true; - if (item.type == ItemID.MechanicalGlove) player.releaseUseItem = true; - } - { - if (item.type == ItemID.FireGauntlet) - { - player.releaseUseItem = true; - player.meleeDamage += 0.02f;// 2% increase - player.meleeSpeed += 0.02f; - } - } - } - } -} \ No newline at end of file diff --git a/NPCs/NPCshops.cs b/NPCs/NPCshops.cs new file mode 100644 index 0000000..d6fd369 --- /dev/null +++ b/NPCs/NPCshops.cs @@ -0,0 +1,22 @@ +using Terraria; +using Terraria.ID; +using Terraria.ModLoader; + +namespace NekoTweakMod.NPCs +{ + public class NPCshops : GlobalNPC + { + public override void SetupShop(int type, Chest shop, ref int nextSlot) // Allows you to add items to NPC shops + { + if(type == NPCID.Merchant) // Specifies the npc we are changing + { + shop.item[nextSlot].SetDefaults(ItemID.MiningShirt); // Add an item with the itemid to the next available slot in the NPCs shop + shop.item[nextSlot].shopCustomPrice = 40000; // sets the purchase cost, 40000 = 4 gold + nextSlot++; + shop.item[nextSlot].SetDefaults(ItemID.MiningPants); + shop.item[nextSlot].shopCustomPrice = 40000; + nextSlot++; + } + } + } +} \ No newline at end of file diff --git a/NekoTweakMod.cs b/NekoTweakMod.cs index 07c95e7..12faf60 100644 --- a/NekoTweakMod.cs +++ b/NekoTweakMod.cs @@ -4,5 +4,6 @@ namespace NekoTweakMod { public class NekoTweakMod : Mod { + //owo whats this } } \ No newline at end of file diff --git a/README.md b/README.md index 637d833..795aaee 100644 --- a/README.md +++ b/README.md @@ -13,6 +13,7 @@ - Lyker - [direwolf420](https://forums.terraria.org/index.php?members/direwolf420.123064/) - thegamemagic1234 +- Oli # **Current Features** @@ -22,6 +23,11 @@ - Muramasa damage changed from 21 to 26 (Bit more competetive damage as it can't apply any debuffs, but also not to much due to its fast attack speed) +- A more linear fishing rod progression with buffs/nerfs to all rods, better early rods + +- Living Tree & Pyramid chest loot from fishing crates *still WIP* +(Finch staff & Sandstorm in a Bottle etc) + - Feral claws changed from "12% increased melee speed" to "melee autoswing" (Melee Autoswing also applies to summoner whips) @@ -43,8 +49,7 @@ - Ivy whip renamed to "Ivy hook" to prevent confusions with the summoner whip weapons - - +- Merchant now sell the full mining set so its achievable early on @@ -75,15 +80,6 @@ - Corrupt,Defiled,Crimson & Hematic crates crates now have a chance to give Bloody tear & Chum Caster (Makes it possible to get bloody tears when no blood moons are happening from evil biome fishing) -- Scarab Fishing Rod & Chum Caster fishing power changed from 25% to 27% - -- Fisher of Souls(20%) & Fleshcatcher(22%) fishing powered changed to 30% and 32% respectively -(corruption/crimson difference - -- Sitting Duck's Fishing Pole fishing power changed from 40% to 35% - -- Mechanic's Rod fishing power changed from 30% to 40% - **Weapon/Armor/Accessorie related:** @@ -101,9 +97,6 @@ **NPC related:** -- Merchant now sell Mining Shirt & Mining Pants for 3 & 2 gold respectively -(So its usable early game and not just vanity once you would have farmed for all pieces. Sell price for both of these still stay at 10silver each) - - Dryad now sell opposite evil biome powder in graveyard biomes - Steampunker now sells the opposite evil biome solution in graveyard biomes diff --git a/build.txt b/build.txt index 393a472..863c809 100644 --- a/build.txt +++ b/build.txt @@ -1,5 +1,5 @@ displayName = Neko's Tweak Mod author = Neko -version = 0.1.1.1 +version = 0.1.2.0 homepage = https://forums.terraria.org/index.php?threads/nekos-tweak-mod.93711/ buildIgnore = obj\*, bin\*, *.csproj, .git\*, .gitattributes, .gitignore, .psd, .sln, ..vs\*, LICENSE \ No newline at end of file diff --git a/description.txt b/description.txt index ac0e14d..488a7f2 100644 --- a/description.txt +++ b/description.txt @@ -3,23 +3,23 @@ Adds several vanilla quality of life and balance changes Few example features: -- Placed buff items like bewitching table,ammo box etc now works like campfires giving you the buff while nearby & for 10minutes after going away +- Placed buff items like bewitching table,ammo box etc now work similar to campfires giving you the buff while nearby & also for 10minutes after -- Muramasa damage changed to 26 +- Muramasa has been buffed -- Feral claws now give "melee autoswing" (Melee Autoswing also applies to summoner whips) +- Living Tree & Pyramid chest loot from fishing crates *still WIP* +(Finch staff & Sandstorm in a Bottle etc) -- Titan glove now give "12% increased melee speed" +- Feral claws now give "melee autoswing" (Melee Autoswing also applies to summoner whips) -- Fire gauntlet melee damage & speed increased from 10% to 12% +- Merchant now sell the full mining set so its achievable early on -- Reaver Shark Use time changed from 22 to 19 (Slightly faster) +- A more linear fishing rod progression with buffs/nerfs to all rods, better early rods - Shackle now gives a small amount of aggro when equipped & also have the tooltip "Enemies are more likely to target you" - Ivy whip renamed to "Ivy hook" to prevent confusions with the summoner whip weapons - -Visit the mod's homepage for a full feature list. +Visit the mod's homepage on the Terraria Forums or on GitHub for a full feature list. UwU \ No newline at end of file diff --git a/obj/Debug/net45/NekoTweakMod.csprojAssemblyReference.cache b/obj/Debug/net45/NekoTweakMod.csprojAssemblyReference.cache index d2ce806..60a872c 100644 Binary files a/obj/Debug/net45/NekoTweakMod.csprojAssemblyReference.cache and b/obj/Debug/net45/NekoTweakMod.csprojAssemblyReference.cache differ