Add crafting to RGBAlloy, Bass, Visor Shard and Shattered Prism

This commit is contained in:
2025-11-10 11:20:37 +00:00
parent 00d44a09e2
commit 2323ef6c08
4 changed files with 19 additions and 3 deletions
+1
View File
@@ -12,6 +12,7 @@ namespace ForgottenWawiTech.Content.Items.Materials
Item.height = 20; Item.height = 20;
Item.maxStack = 9999; Item.maxStack = 9999;
Item.rare = ItemRarityID.White; Item.rare = ItemRarityID.White;
Item.value = Item.buyPrice(gold: 50);
} }
public override void AddRecipes() public override void AddRecipes()
+1
View File
@@ -12,6 +12,7 @@ namespace ForgottenWawiTech.Content.Items.Materials
Item.height = 20; Item.height = 20;
Item.maxStack = 9999; Item.maxStack = 9999;
Item.rare = ItemRarityID.White; Item.rare = ItemRarityID.White;
Item.value = Item.buyPrice(gold: 10);
} }
} }
} }
+1
View File
@@ -12,6 +12,7 @@ namespace ForgottenWawiTech.Content.Items.Materials
Item.height = 20; Item.height = 20;
Item.maxStack = 9999; Item.maxStack = 9999;
Item.rare = ItemRarityID.White; Item.rare = ItemRarityID.White;
Item.value = Item.buyPrice(gold: 1);
} }
} }
} }
+16 -3
View File
@@ -22,11 +22,24 @@ namespace ForgottenWawiTech.Content.Items.Weapons.Magic
Item.color = OverrideColor; Item.color = OverrideColor;
} }
// Because this weapon fires a holdout projectile, it needs to block usage if its projectile already exists. // Because this weapon fires a holdout projectile, it needs to block usage if its projectile already exists.
public override bool CanUseItem(Player player) { public override bool CanUseItem(Player player)
{
return player.ownedProjectileCounts[ModContent.ProjectileType<ShatteredPrismHoldout>()] <= 0; return player.ownedProjectileCounts[ModContent.ProjectileType<ShatteredPrismHoldout>()] <= 0;
} }
public override void AddRecipes()
{
Recipe recipe = CreateRecipe();
// Only add recipe if Calamity Mod is loaded
if (ModLoader.TryGetMod("CalamityMod", out Mod calamityMod))
{
recipe.AddIngredient(ItemID.LastPrism, 1);
recipe.AddIngredient(calamityMod.Find<ModItem>("ShatteredCommunity").Type, 1);
recipe.AddIngredient<Content.Items.Materials.RGBAlloy>(10);
recipe.AddTile<Content.Tiles.CraftingStations.HighTechMarvel>();
recipe.Register();
}
}
} }
} }