Fix damage typing for melee weapons. Fixed recursion bug. Cleaned up variables.
This commit is contained in:
@@ -18,6 +18,7 @@ public class CarbonDagger : ModItem
|
|||||||
public override void SetDefaults()
|
public override void SetDefaults()
|
||||||
{
|
{
|
||||||
Item.damage = 62;
|
Item.damage = 62;
|
||||||
|
Item.DamageType = DamageClass.Melee;
|
||||||
Item.width = 30;
|
Item.width = 30;
|
||||||
Item.height = 30;
|
Item.height = 30;
|
||||||
Item.useTime = 11;
|
Item.useTime = 11;
|
||||||
@@ -36,11 +37,11 @@ public class CarbonDagger : ModItem
|
|||||||
{
|
{
|
||||||
if (Main.rand.NextBool(3))
|
if (Main.rand.NextBool(3))
|
||||||
{
|
{
|
||||||
int num1 = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RyuuDust2>());
|
int dust = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RyuuDust2>());
|
||||||
Main.dust[num1].scale = 1f;
|
Main.dust[dust].scale = 1f;
|
||||||
Main.dust[num1].velocity.Y = 0f;
|
Main.dust[dust].velocity.Y = 0f;
|
||||||
Main.dust[num1].velocity.X = 0.5f;
|
Main.dust[dust].velocity.X = 0.5f;
|
||||||
Main.dust[num1].noGravity = true;
|
Main.dust[dust].noGravity = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -65,17 +66,17 @@ public class CarbonDagger : ModItem
|
|||||||
|
|
||||||
public override void AddRecipes()
|
public override void AddRecipes()
|
||||||
{
|
{
|
||||||
Recipe val = CreateRecipe();
|
Recipe recipe1 = CreateRecipe();
|
||||||
val.AddIngredient(ModContent.ItemType<Wakizashi>());
|
recipe1.AddIngredient(ModContent.ItemType<Wakizashi>());
|
||||||
val.AddRecipeGroup("FabusMod:OrichalcumBar", 6);
|
recipe1.AddRecipeGroup("FabusMod:OrichalcumBar", 6);
|
||||||
val.AddIngredient(ItemID.Sapphire, 2);
|
recipe1.AddIngredient(ItemID.Sapphire, 2);
|
||||||
val.AddTile(TileID.MythrilAnvil);
|
recipe1.AddTile(TileID.MythrilAnvil);
|
||||||
val.Register();
|
recipe1.Register();
|
||||||
|
|
||||||
Recipe val2 = CreateRecipe();
|
Recipe recipe2 = CreateRecipe();
|
||||||
val2.AddIngredient(ModContent.ItemType<CarbonDaggerNihon>());
|
recipe2.AddIngredient(ModContent.ItemType<CarbonDaggerNihon>());
|
||||||
val2.AddIngredient(ItemID.BlueDye, 1);
|
recipe2.AddIngredient(ItemID.BlueDye, 1);
|
||||||
val2.AddTile(TileID.DyeVat);
|
recipe2.AddTile(TileID.DyeVat);
|
||||||
val2.Register();
|
recipe2.Register();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
using FabusMod.Projectiles.Shortsword;
|
|
||||||
using Microsoft.Xna.Framework;
|
using Microsoft.Xna.Framework;
|
||||||
using Terraria;
|
using Terraria;
|
||||||
using Terraria.DataStructures;
|
using Terraria.DataStructures;
|
||||||
@@ -18,6 +17,7 @@ public class CarbonDaggerNihon : ModItem
|
|||||||
public override void SetDefaults()
|
public override void SetDefaults()
|
||||||
{
|
{
|
||||||
Item.damage = 62;
|
Item.damage = 62;
|
||||||
|
Item.DamageType = DamageClass.Melee;
|
||||||
Item.width = 30;
|
Item.width = 30;
|
||||||
Item.height = 30;
|
Item.height = 30;
|
||||||
Item.useTime = 11;
|
Item.useTime = 11;
|
||||||
@@ -28,7 +28,7 @@ public class CarbonDaggerNihon : ModItem
|
|||||||
Item.rare = ItemRarityID.LightRed;
|
Item.rare = ItemRarityID.LightRed;
|
||||||
Item.UseSound = SoundID.Item1;
|
Item.UseSound = SoundID.Item1;
|
||||||
Item.autoReuse = true;
|
Item.autoReuse = true;
|
||||||
Item.shoot = ModContent.ProjectileType<CarbonKnifeNihon>();
|
Item.shoot = ModContent.ProjectileType<Projectiles.Shortsword.CarbonKnifeNihon>();
|
||||||
Item.shootSpeed = 10f;
|
Item.shootSpeed = 10f;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -36,11 +36,11 @@ public class CarbonDaggerNihon : ModItem
|
|||||||
{
|
{
|
||||||
if (Main.rand.NextBool(3))
|
if (Main.rand.NextBool(3))
|
||||||
{
|
{
|
||||||
int num1 = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.OniDust>());
|
int dust = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.OniDust>());
|
||||||
Main.dust[num1].scale = 1f;
|
Main.dust[dust].scale = 1f;
|
||||||
Main.dust[num1].velocity.Y = 0f;
|
Main.dust[dust].velocity.Y = 0f;
|
||||||
Main.dust[num1].velocity.X = 0.5f;
|
Main.dust[dust].velocity.X = 0.5f;
|
||||||
Main.dust[num1].noGravity = true;
|
Main.dust[dust].noGravity = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -18,6 +18,7 @@ public class GoldenDagger : ModItem
|
|||||||
public override void SetDefaults()
|
public override void SetDefaults()
|
||||||
{
|
{
|
||||||
Item.damage = 95;
|
Item.damage = 95;
|
||||||
|
Item.DamageType = DamageClass.Melee;
|
||||||
Item.width = 40;
|
Item.width = 40;
|
||||||
Item.height = 40;
|
Item.height = 40;
|
||||||
Item.useTime = 12;
|
Item.useTime = 12;
|
||||||
@@ -36,11 +37,11 @@ public class GoldenDagger : ModItem
|
|||||||
{
|
{
|
||||||
if (Main.rand.NextBool(3))
|
if (Main.rand.NextBool(3))
|
||||||
{
|
{
|
||||||
int num1 = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.MeatDust>(), 0f, 0f, 0, default, 1f);
|
int dust = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.MeatDust>());
|
||||||
Main.dust[num1].scale = 1f;
|
Main.dust[dust].scale = 1f;
|
||||||
Main.dust[num1].velocity.Y = 0f;
|
Main.dust[dust].velocity.Y = 0f;
|
||||||
Main.dust[num1].velocity.X = 0.5f;
|
Main.dust[dust].velocity.X = 0.5f;
|
||||||
Main.dust[num1].noGravity = true;
|
Main.dust[dust].noGravity = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -74,11 +75,11 @@ public class GoldenDagger : ModItem
|
|||||||
|
|
||||||
public override void AddRecipes()
|
public override void AddRecipes()
|
||||||
{
|
{
|
||||||
Recipe val = CreateRecipe();
|
Recipe recipe = CreateRecipe();
|
||||||
val.AddIngredient(ModContent.ItemType<OniDagger>());
|
recipe.AddIngredient(ModContent.ItemType<OniDagger>());
|
||||||
val.AddIngredient(ModContent.ItemType<Items.CraftingIngredients.GoddessGold>(), 6);
|
recipe.AddIngredient(ModContent.ItemType<Items.CraftingIngredients.GoddessGold>(), 6);
|
||||||
val.AddIngredient(ModContent.ItemType<Items.CraftingIngredients.SoulofWisdom>(), 4);
|
recipe.AddIngredient(ModContent.ItemType<Items.CraftingIngredients.SoulofWisdom>(), 4);
|
||||||
val.AddTile(TileID.AdamantiteForge);
|
recipe.AddTile(TileID.AdamantiteForge);
|
||||||
val.Register();
|
recipe.Register();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -17,6 +17,7 @@ public class OniDagger : ModItem
|
|||||||
public override void SetDefaults()
|
public override void SetDefaults()
|
||||||
{
|
{
|
||||||
Item.damage = 92;
|
Item.damage = 92;
|
||||||
|
Item.DamageType = DamageClass.Melee;
|
||||||
Item.width = 40;
|
Item.width = 40;
|
||||||
Item.height = 40;
|
Item.height = 40;
|
||||||
Item.useTime = 11;
|
Item.useTime = 11;
|
||||||
@@ -35,11 +36,11 @@ public class OniDagger : ModItem
|
|||||||
{
|
{
|
||||||
if (Main.rand.NextBool(3))
|
if (Main.rand.NextBool(3))
|
||||||
{
|
{
|
||||||
int num1 = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RyuuDust3>());
|
int dust = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RyuuDust3>());
|
||||||
Main.dust[num1].scale = 1f;
|
Main.dust[dust].scale = 1f;
|
||||||
Main.dust[num1].velocity.Y = 0f;
|
Main.dust[dust].velocity.Y = 0f;
|
||||||
Main.dust[num1].velocity.X = 0.5f;
|
Main.dust[dust].velocity.X = 0.5f;
|
||||||
Main.dust[num1].noGravity = true;
|
Main.dust[dust].noGravity = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -65,12 +66,12 @@ public class OniDagger : ModItem
|
|||||||
|
|
||||||
public override void AddRecipes()
|
public override void AddRecipes()
|
||||||
{
|
{
|
||||||
Recipe val = CreateRecipe();
|
Recipe recipe = CreateRecipe();
|
||||||
val.AddRecipeGroup("FabusMod:CarbonDagger", 1);
|
recipe.AddRecipeGroup("FabusMod:CarbonDagger", 1);
|
||||||
val.AddRecipeGroup("FabusMod:AdamantiteBar", 6);
|
recipe.AddRecipeGroup("FabusMod:AdamantiteBar", 6);
|
||||||
val.AddIngredient(ItemID.SoulofNight, 4);
|
recipe.AddIngredient(ItemID.SoulofNight, 4);
|
||||||
val.AddIngredient(ModContent.ItemType<Items.CraftingIngredients.SoulofWisdom>(), 2);
|
recipe.AddIngredient(ModContent.ItemType<Items.CraftingIngredients.SoulofWisdom>(), 2);
|
||||||
val.AddTile(TileID.MythrilAnvil);
|
recipe.AddTile(TileID.MythrilAnvil);
|
||||||
val.Register();
|
recipe.Register();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -14,6 +14,7 @@ public class StonePlatedShortsword : ModItem
|
|||||||
public override void SetDefaults()
|
public override void SetDefaults()
|
||||||
{
|
{
|
||||||
Item.damage = 9;
|
Item.damage = 9;
|
||||||
|
Item.DamageType = DamageClass.Melee;
|
||||||
Item.width = 30;
|
Item.width = 30;
|
||||||
Item.height = 30;
|
Item.height = 30;
|
||||||
Item.useTime = 13;
|
Item.useTime = 13;
|
||||||
@@ -28,10 +29,10 @@ public class StonePlatedShortsword : ModItem
|
|||||||
|
|
||||||
public override void AddRecipes()
|
public override void AddRecipes()
|
||||||
{
|
{
|
||||||
Recipe val = CreateRecipe();
|
Recipe recipe = CreateRecipe();
|
||||||
val.AddIngredient(ModContent.ItemType<Items.WeaponParts.UntreatedShortswordPart>());
|
recipe.AddIngredient(ModContent.ItemType<Items.WeaponParts.UntreatedShortswordPart>());
|
||||||
val.AddIngredient(ItemID.StoneBlock, 6);
|
recipe.AddIngredient(ItemID.StoneBlock, 6);
|
||||||
val.AddTile(ModContent.TileType<global::FabusMod.Tiles.ReinforcedWorkBench>());
|
recipe.AddTile(ModContent.TileType<global::FabusMod.Tiles.ReinforcedWorkBench>());
|
||||||
val.Register();
|
recipe.Register();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -17,6 +17,7 @@ public class TheRainbowsCurse : ModItem
|
|||||||
public override void SetDefaults()
|
public override void SetDefaults()
|
||||||
{
|
{
|
||||||
Item.damage = 154;
|
Item.damage = 154;
|
||||||
|
Item.DamageType = DamageClass.Melee;
|
||||||
Item.width = 48;
|
Item.width = 48;
|
||||||
Item.height = 48;
|
Item.height = 48;
|
||||||
Item.useTime = 8;
|
Item.useTime = 8;
|
||||||
@@ -35,21 +36,23 @@ public class TheRainbowsCurse : ModItem
|
|||||||
{
|
{
|
||||||
if (Main.rand.NextBool(3))
|
if (Main.rand.NextBool(3))
|
||||||
{
|
{
|
||||||
int num1 = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RainbowDust>());
|
int dust1 = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RainbowDust>());
|
||||||
int num2 = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RainbowDust2>());
|
Main.dust[dust1].scale = 1f;
|
||||||
int num3 = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RainbowDust3>());
|
Main.dust[dust1].velocity.Y = 0f;
|
||||||
Main.dust[num1].scale = 1f;
|
Main.dust[dust1].velocity.X = 0.5f;
|
||||||
Main.dust[num1].velocity.Y = 0f;
|
Main.dust[dust1].noGravity = true;
|
||||||
Main.dust[num1].velocity.X = 0.5f;
|
|
||||||
Main.dust[num1].noGravity = true;
|
int dust2 = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RainbowDust2>());
|
||||||
Main.dust[num2].scale = 1f;
|
Main.dust[dust2].scale = 1f;
|
||||||
Main.dust[num2].velocity.Y = 0f;
|
Main.dust[dust2].velocity.Y = 0f;
|
||||||
Main.dust[num2].velocity.X = 0.5f;
|
Main.dust[dust2].velocity.X = 0.5f;
|
||||||
Main.dust[num2].noGravity = true;
|
Main.dust[dust2].noGravity = true;
|
||||||
Main.dust[num3].scale = 1f;
|
|
||||||
Main.dust[num3].velocity.Y = 0f;
|
int dust3 = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RainbowDust3>());
|
||||||
Main.dust[num3].velocity.X = 0.5f;
|
Main.dust[dust3].scale = 1f;
|
||||||
Main.dust[num3].noGravity = true;
|
Main.dust[dust3].velocity.Y = 0f;
|
||||||
|
Main.dust[dust3].velocity.X = 0.5f;
|
||||||
|
Main.dust[dust3].noGravity = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -83,10 +86,10 @@ public class TheRainbowsCurse : ModItem
|
|||||||
|
|
||||||
public override void AddRecipes()
|
public override void AddRecipes()
|
||||||
{
|
{
|
||||||
Recipe val = CreateRecipe();
|
Recipe recipe = CreateRecipe();
|
||||||
val.AddIngredient(ModContent.ItemType<GoldenDagger>());
|
recipe.AddIngredient(ModContent.ItemType<GoldenDagger>());
|
||||||
val.AddIngredient(ModContent.ItemType<Bars.RainbowChunk>(), 6);
|
recipe.AddIngredient(ModContent.ItemType<Bars.RainbowChunk>(), 6);
|
||||||
val.AddTile(ModContent.TileType<global::FabusMod.Tiles.RainbowStation>());
|
recipe.AddTile(ModContent.TileType<global::FabusMod.Tiles.RainbowStation>());
|
||||||
val.Register();
|
recipe.Register();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,6 +16,7 @@ public class Wakizashi : ModItem
|
|||||||
public override void SetDefaults()
|
public override void SetDefaults()
|
||||||
{
|
{
|
||||||
Item.damage = 15;
|
Item.damage = 15;
|
||||||
|
Item.DamageType = DamageClass.Melee;
|
||||||
Item.width = 30;
|
Item.width = 30;
|
||||||
Item.height = 30;
|
Item.height = 30;
|
||||||
Item.useTime = 13;
|
Item.useTime = 13;
|
||||||
@@ -32,11 +33,11 @@ public class Wakizashi : ModItem
|
|||||||
{
|
{
|
||||||
if (Main.rand.NextBool(3))
|
if (Main.rand.NextBool(3))
|
||||||
{
|
{
|
||||||
int num1 = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RyuuDust>());
|
int dust = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RyuuDust>());
|
||||||
Main.dust[num1].scale = 1f;
|
Main.dust[dust].scale = 1f;
|
||||||
Main.dust[num1].velocity.Y = 0f;
|
Main.dust[dust].velocity.Y = 0f;
|
||||||
Main.dust[num1].velocity.X = 0.5f;
|
Main.dust[dust].velocity.X = 0.5f;
|
||||||
Main.dust[num1].noGravity = true;
|
Main.dust[dust].noGravity = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -47,11 +48,11 @@ public class Wakizashi : ModItem
|
|||||||
|
|
||||||
public override void AddRecipes()
|
public override void AddRecipes()
|
||||||
{
|
{
|
||||||
Recipe val = CreateRecipe();
|
Recipe recipe = CreateRecipe();
|
||||||
val.AddIngredient(ModContent.ItemType<StonePlatedShortsword>());
|
recipe.AddIngredient(ModContent.ItemType<StonePlatedShortsword>());
|
||||||
val.AddRecipeGroup("IronBar", 6);
|
recipe.AddRecipeGroup("IronBar", 6);
|
||||||
val.AddIngredient(ItemID.Emerald, 2);
|
recipe.AddIngredient(ItemID.Emerald, 2);
|
||||||
val.AddTile(TileID.Anvils);
|
recipe.AddTile(TileID.Anvils);
|
||||||
val.Register();
|
recipe.Register();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -18,6 +18,7 @@ public class CarbonSword : ModItem
|
|||||||
public override void SetDefaults()
|
public override void SetDefaults()
|
||||||
{
|
{
|
||||||
Item.damage = 74;
|
Item.damage = 74;
|
||||||
|
Item.DamageType = DamageClass.Melee;
|
||||||
Item.crit = 8;
|
Item.crit = 8;
|
||||||
Item.width = 54;
|
Item.width = 54;
|
||||||
Item.height = 68;
|
Item.height = 68;
|
||||||
@@ -48,11 +49,11 @@ public class CarbonSword : ModItem
|
|||||||
{
|
{
|
||||||
if (Main.rand.NextBool(3))
|
if (Main.rand.NextBool(3))
|
||||||
{
|
{
|
||||||
int num1 = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RyuuDust2>());
|
int dust = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RyuuDust2>());
|
||||||
Main.dust[num1].scale = 1f;
|
Main.dust[dust].scale = 1f;
|
||||||
Main.dust[num1].velocity.Y = 0f;
|
Main.dust[dust].velocity.Y = 0f;
|
||||||
Main.dust[num1].velocity.X = 0.5f;
|
Main.dust[dust].velocity.X = 0.5f;
|
||||||
Main.dust[num1].noGravity = true;
|
Main.dust[dust].noGravity = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -63,16 +64,16 @@ public class CarbonSword : ModItem
|
|||||||
|
|
||||||
public override void AddRecipes()
|
public override void AddRecipes()
|
||||||
{
|
{
|
||||||
Recipe val = CreateRecipe();
|
Recipe recipe1 = CreateRecipe();
|
||||||
val.AddIngredient(ModContent.ItemType<ShimadaSword>());
|
recipe1.AddIngredient(ModContent.ItemType<ShimadaSword>());
|
||||||
val.AddRecipeGroup("FabusMod:OrichalcumBar", 10);
|
recipe1.AddRecipeGroup("FabusMod:OrichalcumBar", 10);
|
||||||
val.AddTile(TileID.DemonAltar);
|
recipe1.AddTile(TileID.DemonAltar);
|
||||||
val.Register();
|
recipe1.Register();
|
||||||
|
|
||||||
Recipe val2 = CreateRecipe();
|
Recipe recipe2 = CreateRecipe();
|
||||||
val2.AddIngredient(ModContent.ItemType<CarbonSwordNihon>());
|
recipe2.AddIngredient(ModContent.ItemType<CarbonSwordNihon>());
|
||||||
val2.AddIngredient(ItemID.BlueDye, 1);
|
recipe2.AddIngredient(ItemID.BlueDye, 1);
|
||||||
val2.AddTile(TileID.DyeVat);
|
recipe2.AddTile(TileID.DyeVat);
|
||||||
val2.Register();
|
recipe2.Register();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -18,6 +18,7 @@ public class CarbonSwordNihon : ModItem
|
|||||||
public override void SetDefaults()
|
public override void SetDefaults()
|
||||||
{
|
{
|
||||||
Item.damage = 74;
|
Item.damage = 74;
|
||||||
|
Item.DamageType = DamageClass.Melee;
|
||||||
Item.crit = 8;
|
Item.crit = 8;
|
||||||
Item.width = 54;
|
Item.width = 54;
|
||||||
Item.height = 68;
|
Item.height = 68;
|
||||||
@@ -53,20 +54,20 @@ public class CarbonSwordNihon : ModItem
|
|||||||
{
|
{
|
||||||
if (Main.rand.NextBool(3))
|
if (Main.rand.NextBool(3))
|
||||||
{
|
{
|
||||||
int num1 = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.NightsAxeSparkle>());
|
int dust = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.NightsAxeSparkle>());
|
||||||
Main.dust[num1].scale = 1f;
|
Main.dust[dust].scale = 1f;
|
||||||
Main.dust[num1].velocity.Y = 0f;
|
Main.dust[dust].velocity.Y = 0f;
|
||||||
Main.dust[num1].velocity.X = 0.5f;
|
Main.dust[dust].velocity.X = 0.5f;
|
||||||
Main.dust[num1].noGravity = true;
|
Main.dust[dust].noGravity = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public override void AddRecipes()
|
public override void AddRecipes()
|
||||||
{
|
{
|
||||||
Recipe val = CreateRecipe();
|
Recipe recipe = CreateRecipe();
|
||||||
val.AddIngredient(ModContent.ItemType<CarbonSword>());
|
recipe.AddIngredient(ModContent.ItemType<CarbonSword>());
|
||||||
val.AddIngredient(ItemID.SilverDye, 1);
|
recipe.AddIngredient(ItemID.SilverDye, 1);
|
||||||
val.AddTile(TileID.DyeVat);
|
recipe.AddTile(TileID.DyeVat);
|
||||||
val.Register();
|
recipe.Register();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -17,6 +17,7 @@ public class DemonsFury : ModItem
|
|||||||
public override void SetDefaults()
|
public override void SetDefaults()
|
||||||
{
|
{
|
||||||
Item.damage = 80;
|
Item.damage = 80;
|
||||||
|
Item.DamageType = DamageClass.Melee;
|
||||||
Item.crit = 8;
|
Item.crit = 8;
|
||||||
Item.width = 63;
|
Item.width = 63;
|
||||||
Item.height = 76;
|
Item.height = 76;
|
||||||
@@ -41,11 +42,11 @@ public class DemonsFury : ModItem
|
|||||||
{
|
{
|
||||||
if (Main.rand.NextBool(3))
|
if (Main.rand.NextBool(3))
|
||||||
{
|
{
|
||||||
int num1 = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RyuuDust3>());
|
int dust = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RyuuDust3>());
|
||||||
Main.dust[num1].scale = 1f;
|
Main.dust[dust].scale = 1f;
|
||||||
Main.dust[num1].velocity.Y = 0f;
|
Main.dust[dust].velocity.Y = 0f;
|
||||||
Main.dust[num1].velocity.X = 0.5f;
|
Main.dust[dust].velocity.X = 0.5f;
|
||||||
Main.dust[num1].noGravity = true;
|
Main.dust[dust].noGravity = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -83,17 +84,17 @@ public class DemonsFury : ModItem
|
|||||||
}
|
}
|
||||||
Item.UseSound = SoundID.Item1;
|
Item.UseSound = SoundID.Item1;
|
||||||
}
|
}
|
||||||
return CanUseItem(player);
|
return base.CanUseItem(player);
|
||||||
}
|
}
|
||||||
|
|
||||||
public override void AddRecipes()
|
public override void AddRecipes()
|
||||||
{
|
{
|
||||||
Recipe val = CreateRecipe();
|
Recipe recipe = CreateRecipe();
|
||||||
val.AddRecipeGroup("FabusMod:CarbonSword", 1);
|
recipe.AddRecipeGroup("FabusMod:CarbonSword", 1);
|
||||||
val.AddRecipeGroup("FabusMod:AdamantiteBar", 10);
|
recipe.AddRecipeGroup("FabusMod:AdamantiteBar", 10);
|
||||||
val.AddIngredient(ItemID.SoulofNight, 8);
|
recipe.AddIngredient(ItemID.SoulofNight, 8);
|
||||||
val.AddIngredient(ModContent.ItemType<Items.CraftingIngredients.SoulofWisdom>(), 4);
|
recipe.AddIngredient(ModContent.ItemType<Items.CraftingIngredients.SoulofWisdom>(), 4);
|
||||||
val.AddTile(TileID.DemonAltar);
|
recipe.AddTile(TileID.DemonAltar);
|
||||||
val.Register();
|
recipe.Register();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -17,6 +17,7 @@ public class GoldenFury : ModItem
|
|||||||
public override void SetDefaults()
|
public override void SetDefaults()
|
||||||
{
|
{
|
||||||
Item.damage = 100;
|
Item.damage = 100;
|
||||||
|
Item.DamageType = DamageClass.Melee;
|
||||||
Item.crit = 8;
|
Item.crit = 8;
|
||||||
Item.width = 63;
|
Item.width = 63;
|
||||||
Item.height = 76;
|
Item.height = 76;
|
||||||
@@ -83,16 +84,16 @@ public class GoldenFury : ModItem
|
|||||||
}
|
}
|
||||||
Item.UseSound = SoundID.Item1;
|
Item.UseSound = SoundID.Item1;
|
||||||
}
|
}
|
||||||
return this.CanUseItem(player);
|
return base.CanUseItem(player);
|
||||||
}
|
}
|
||||||
|
|
||||||
public override void AddRecipes()
|
public override void AddRecipes()
|
||||||
{
|
{
|
||||||
Recipe val = CreateRecipe();
|
Recipe recipe = CreateRecipe();
|
||||||
val.AddIngredient(ModContent.ItemType<DemonsFury>());
|
recipe.AddIngredient(ModContent.ItemType<DemonsFury>());
|
||||||
val.AddIngredient(ModContent.ItemType<Items.CraftingIngredients.GoddessGold>(), 10);
|
recipe.AddIngredient(ModContent.ItemType<Items.CraftingIngredients.GoddessGold>(), 10);
|
||||||
val.AddIngredient(ModContent.ItemType<Items.CraftingIngredients.SoulofWisdom>(), 4);
|
recipe.AddIngredient(ModContent.ItemType<Items.CraftingIngredients.SoulofWisdom>(), 4);
|
||||||
val.AddTile(TileID.DemonAltar);
|
recipe.AddTile(TileID.DemonAltar);
|
||||||
val.Register();
|
recipe.Register();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,6 +16,7 @@ public class ShimadaSword : ModItem
|
|||||||
public override void SetDefaults()
|
public override void SetDefaults()
|
||||||
{
|
{
|
||||||
Item.damage = 18;
|
Item.damage = 18;
|
||||||
|
Item.DamageType = DamageClass.Melee;
|
||||||
Item.crit = 8;
|
Item.crit = 8;
|
||||||
Item.width = 54;
|
Item.width = 54;
|
||||||
Item.height = 68;
|
Item.height = 68;
|
||||||
@@ -33,11 +34,11 @@ public class ShimadaSword : ModItem
|
|||||||
{
|
{
|
||||||
if (Main.rand.NextBool(3))
|
if (Main.rand.NextBool(3))
|
||||||
{
|
{
|
||||||
int num1 = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RyuuDust>());
|
int dust = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RyuuDust>());
|
||||||
Main.dust[num1].scale = 1f;
|
Main.dust[dust].scale = 1f;
|
||||||
Main.dust[num1].velocity.Y = 0f;
|
Main.dust[dust].velocity.Y = 0f;
|
||||||
Main.dust[num1].velocity.X = 0.5f;
|
Main.dust[dust].velocity.X = 0.5f;
|
||||||
Main.dust[num1].noGravity = true;
|
Main.dust[dust].noGravity = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -48,11 +49,11 @@ public class ShimadaSword : ModItem
|
|||||||
|
|
||||||
public override void AddRecipes()
|
public override void AddRecipes()
|
||||||
{
|
{
|
||||||
Recipe val = CreateRecipe();
|
Recipe recipe = CreateRecipe();
|
||||||
val.AddIngredient(ModContent.ItemType<StonePlatedKatana>());
|
recipe.AddIngredient(ModContent.ItemType<StonePlatedKatana>());
|
||||||
val.AddRecipeGroup("FabusMod:LightsBane");
|
recipe.AddRecipeGroup("FabusMod:LightsBane");
|
||||||
val.AddIngredient(ItemID.Emerald, 10);
|
recipe.AddIngredient(ItemID.Emerald, 10);
|
||||||
val.AddTile(TileID.Anvils);
|
recipe.AddTile(TileID.Anvils);
|
||||||
val.Register();
|
recipe.Register();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -14,6 +14,7 @@ public class StonePlatedKatana : ModItem
|
|||||||
public override void SetDefaults()
|
public override void SetDefaults()
|
||||||
{
|
{
|
||||||
Item.damage = 8;
|
Item.damage = 8;
|
||||||
|
Item.DamageType = DamageClass.Melee;
|
||||||
Item.crit = 8;
|
Item.crit = 8;
|
||||||
Item.width = 56;
|
Item.width = 56;
|
||||||
Item.height = 66;
|
Item.height = 66;
|
||||||
@@ -29,10 +30,10 @@ public class StonePlatedKatana : ModItem
|
|||||||
|
|
||||||
public override void AddRecipes()
|
public override void AddRecipes()
|
||||||
{
|
{
|
||||||
Recipe val = CreateRecipe();
|
Recipe recipe = CreateRecipe();
|
||||||
val.AddIngredient(ModContent.ItemType<Items.WeaponParts.UntreatedSwordParts>());
|
recipe.AddIngredient(ModContent.ItemType<Items.WeaponParts.UntreatedSwordParts>());
|
||||||
val.AddIngredient(ItemID.StoneBlock, 12);
|
recipe.AddIngredient(ItemID.StoneBlock, 12);
|
||||||
val.AddTile(ModContent.TileType<global::FabusMod.Tiles.ReinforcedWorkBench>());
|
recipe.AddTile(ModContent.TileType<global::FabusMod.Tiles.ReinforcedWorkBench>());
|
||||||
val.Register();
|
recipe.Register();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -17,6 +17,7 @@ public class TheRainbowsHonor : ModItem
|
|||||||
public override void SetDefaults()
|
public override void SetDefaults()
|
||||||
{
|
{
|
||||||
Item.damage = 195;
|
Item.damage = 195;
|
||||||
|
Item.DamageType = DamageClass.Melee;
|
||||||
Item.crit = 8;
|
Item.crit = 8;
|
||||||
Item.width = 56;
|
Item.width = 56;
|
||||||
Item.height = 76;
|
Item.height = 76;
|
||||||
@@ -41,21 +42,23 @@ public class TheRainbowsHonor : ModItem
|
|||||||
{
|
{
|
||||||
if (Main.rand.NextBool(3))
|
if (Main.rand.NextBool(3))
|
||||||
{
|
{
|
||||||
int num1 = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RainbowDust>(), 0f, 0f, 0, default(Color), 1f);
|
int dust1 = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RainbowDust>(), 0f, 0f, 0, default(Color), 1f);
|
||||||
Main.dust[num1].scale = 1f;
|
Main.dust[dust1].scale = 1f;
|
||||||
Main.dust[num1].velocity.Y = 0f;
|
Main.dust[dust1].velocity.Y = 0f;
|
||||||
Main.dust[num1].velocity.X = 0.5f;
|
Main.dust[dust1].velocity.X = 0.5f;
|
||||||
Main.dust[num1].noGravity = true;
|
Main.dust[dust1].noGravity = true;
|
||||||
int num2 = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RainbowDust2>(), 0f, 0f, 0, default(Color), 1f);
|
|
||||||
Main.dust[num2].scale = 1f;
|
int dust2 = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RainbowDust2>(), 0f, 0f, 0, default(Color), 1f);
|
||||||
Main.dust[num2].velocity.Y = 0f;
|
Main.dust[dust2].scale = 1f;
|
||||||
Main.dust[num2].velocity.X = 0.5f;
|
Main.dust[dust2].velocity.Y = 0f;
|
||||||
Main.dust[num2].noGravity = true;
|
Main.dust[dust2].velocity.X = 0.5f;
|
||||||
int num3 = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RainbowDust3>(), 0f, 0f, 0, default(Color), 1f);
|
Main.dust[dust2].noGravity = true;
|
||||||
Main.dust[num3].scale = 1f;
|
|
||||||
Main.dust[num3].velocity.Y = 0f;
|
int dust3 = Dust.NewDust(new Vector2(hitbox.X, hitbox.Y), hitbox.Width, hitbox.Height, ModContent.DustType<Dusts.RainbowDust3>(), 0f, 0f, 0, default(Color), 1f);
|
||||||
Main.dust[num3].velocity.X = 0.5f;
|
Main.dust[dust3].scale = 1f;
|
||||||
Main.dust[num3].noGravity = true;
|
Main.dust[dust3].velocity.Y = 0f;
|
||||||
|
Main.dust[dust3].velocity.X = 0.5f;
|
||||||
|
Main.dust[dust3].noGravity = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -93,15 +96,15 @@ public class TheRainbowsHonor : ModItem
|
|||||||
}
|
}
|
||||||
Item.UseSound = SoundID.Item1;
|
Item.UseSound = SoundID.Item1;
|
||||||
}
|
}
|
||||||
return this.CanUseItem(player);
|
return base.CanUseItem(player);
|
||||||
}
|
}
|
||||||
|
|
||||||
public override void AddRecipes()
|
public override void AddRecipes()
|
||||||
{
|
{
|
||||||
Recipe val = CreateRecipe();
|
Recipe recipe = CreateRecipe();
|
||||||
val.AddIngredient(ModContent.ItemType<GoldenFury>());
|
recipe.AddIngredient(ModContent.ItemType<GoldenFury>());
|
||||||
val.AddIngredient(ModContent.ItemType<Bars.RainbowChunk>(), 10);
|
recipe.AddIngredient(ModContent.ItemType<Bars.RainbowChunk>(), 10);
|
||||||
val.AddTile(null, "RainbowStation");
|
recipe.AddTile(null, "RainbowStation");
|
||||||
val.Register();
|
recipe.Register();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -18,6 +18,7 @@ public class RainbowAxe : ModItem
|
|||||||
public override void SetDefaults()
|
public override void SetDefaults()
|
||||||
{
|
{
|
||||||
Item.damage = 280;
|
Item.damage = 280;
|
||||||
|
Item.DamageType = DamageClass.Melee;
|
||||||
Item.width = 54;
|
Item.width = 54;
|
||||||
Item.height = 58;
|
Item.height = 58;
|
||||||
Item.useTime = 20;
|
Item.useTime = 20;
|
||||||
@@ -70,7 +71,7 @@ public class RainbowAxe : ModItem
|
|||||||
Item.tileBoost = 6;
|
Item.tileBoost = 6;
|
||||||
Item.shoot = ProjectileID.None;
|
Item.shoot = ProjectileID.None;
|
||||||
}
|
}
|
||||||
return this.CanUseItem(player);
|
return base.CanUseItem(player);
|
||||||
}
|
}
|
||||||
|
|
||||||
public override bool Shoot(Player player, EntitySource_ItemUse_WithAmmo source, Vector2 position, Vector2 velocity, int type, int damage, float knockback)
|
public override bool Shoot(Player player, EntitySource_ItemUse_WithAmmo source, Vector2 position, Vector2 velocity, int type, int damage, float knockback)
|
||||||
@@ -88,13 +89,13 @@ public class RainbowAxe : ModItem
|
|||||||
|
|
||||||
public override void AddRecipes()
|
public override void AddRecipes()
|
||||||
{
|
{
|
||||||
Recipe val = CreateRecipe();
|
Recipe recipe = CreateRecipe();
|
||||||
val.AddIngredient(ItemID.LunarHamaxeSolar);
|
recipe.AddIngredient(ItemID.LunarHamaxeSolar);
|
||||||
val.AddIngredient(ItemID.LunarHamaxeVortex);
|
recipe.AddIngredient(ItemID.LunarHamaxeVortex);
|
||||||
val.AddIngredient(ItemID.LunarHamaxeNebula);
|
recipe.AddIngredient(ItemID.LunarHamaxeNebula);
|
||||||
val.AddIngredient(ItemID.LunarHamaxeStardust);
|
recipe.AddIngredient(ItemID.LunarHamaxeStardust);
|
||||||
val.AddIngredient(ModContent.ItemType<Bars.RainbowChunk>(), 14);
|
recipe.AddIngredient(ModContent.ItemType<Bars.RainbowChunk>(), 14);
|
||||||
val.AddTile(ModContent.TileType<global::FabusMod.Tiles.RainbowStation>());
|
recipe.AddTile(ModContent.TileType<global::FabusMod.Tiles.RainbowStation>());
|
||||||
val.Register();
|
recipe.Register();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user