Added critter related sprites for the bab
This commit is contained in:
1 parent
6c45e68eb6
commit
c5f5e843a1
10 files changed
+139
-2
No files matched your search
@@ -0,0 +1,33 @@
|
||||
using CalamityMod.NPCs.Abyss;
|
||||
using Terraria;
|
||||
using Terraria.ModLoader;
|
||||
using Terraria.ID;
|
||||
|
||||
namespace CalamityMod.Items.Critters
|
||||
{
|
||||
public class BabyCannonballJellyfishItem : ModItem, ILocalizedModType
|
||||
{
|
||||
public new string LocalizationCategory => "Items.Misc";
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
Item.ResearchUnlockCount = 5;
|
||||
}
|
||||
//Intentionally NOT bait due to bestiary entry on them being used as ammunition, although dynamite fishing in terraria does sound pretty fun
|
||||
public override void SetDefaults()
|
||||
{
|
||||
Item.useStyle = ItemUseStyleID.Swing;
|
||||
Item.autoReuse = true;
|
||||
Item.useTurn = true;
|
||||
Item.useAnimation = 15;
|
||||
Item.useTime = 10;
|
||||
Item.maxStack = 9999;
|
||||
Item.consumable = true;
|
||||
Item.noUseGraphic = true;
|
||||
Item.value = Item.buyPrice(0, 0, 30, 0);
|
||||
Item.width = 26;
|
||||
Item.height = 24;
|
||||
Item.makeNPC = (short)ModContent.NPCType<BabyCannonballJellyfish>();
|
||||
Item.rare = ItemRarityID.Green;
|
||||
}
|
||||
}
|
||||
}
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 475 B |
@@ -0,0 +1,30 @@
|
||||
using CalamityMod.Tiles.Furniture;
|
||||
using CalamityMod.Items.Critters;
|
||||
using Terraria.ID;
|
||||
using Terraria.ModLoader;
|
||||
|
||||
namespace CalamityMod.Items.Placeables.Furniture
|
||||
{
|
||||
public class BabyCannonballJellyfishBowl : ModItem, ILocalizedModType
|
||||
{
|
||||
public new string LocalizationCategory => "Items.Placeables";
|
||||
public override void SetDefaults()
|
||||
{
|
||||
Item.width = 34;
|
||||
Item.height = 32;
|
||||
Item.maxStack = 9999;
|
||||
Item.useTurn = true;
|
||||
Item.autoReuse = true;
|
||||
Item.useAnimation = 15;
|
||||
Item.useTime = 10;
|
||||
Item.useStyle = ItemUseStyleID.Swing;
|
||||
Item.consumable = true;
|
||||
Item.createTile = ModContent.TileType<BabyCannonballJellyfishBowlTile>();
|
||||
}
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe(1).AddIngredient(ModContent.ItemType<BabyCannonballJellyfishItem>()).AddIngredient(ItemID.BottledWater).Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 692 B |
@@ -24,7 +24,7 @@ namespace CalamityMod.Items.Placeables.Furniture
|
||||
|
||||
public override void AddRecipes()
|
||||
{
|
||||
CreateRecipe(1).AddIngredient(ModContent.ItemType<BabyGhostBellItem>()).AddIngredient(ItemID.Bottle).Register();
|
||||
CreateRecipe(1).AddIngredient(ModContent.ItemType<BabyGhostBellItem>()).AddIngredient(ItemID.BottledWater).Register();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -8,6 +8,11 @@ AndroombaItem: {
|
||||
'''
|
||||
}
|
||||
|
||||
BabyCannonballJellyfishItem: {
|
||||
DisplayName: "{$Mods.CalamityMod.NPCs.BabyCannonballJellyfish.DisplayName}"
|
||||
Tooltip: ""
|
||||
}
|
||||
|
||||
BabyFlakCrabItem: {
|
||||
DisplayName: "{$Mods.CalamityMod.NPCs.BabyFlakCrab.DisplayName}"
|
||||
Tooltip: ""
|
||||
|
||||
@@ -910,6 +910,11 @@ AuricToilet: {
|
||||
'''
|
||||
}
|
||||
|
||||
BabyCannonballJellyfishBowl: {
|
||||
DisplayName: Baby Cannonball Jellyfish Bowl
|
||||
Tooltip: ""
|
||||
}
|
||||
|
||||
BabyFlakCrabCage: {
|
||||
DisplayName: Baby Flak Crab Cage
|
||||
Tooltip: ""
|
||||
|
||||
@@ -3,6 +3,7 @@ using Microsoft.Xna.Framework;
|
||||
using Microsoft.Xna.Framework.Graphics;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using CalamityMod.Items.Critters;
|
||||
using CalamityMod.Items.Placeables.Banners;
|
||||
using Terraria;
|
||||
using Terraria.GameContent;
|
||||
@@ -44,7 +45,7 @@ namespace CalamityMod.NPCs.Abyss
|
||||
NPC.DeathSound = SoundID.NPCDeath28;
|
||||
Banner = NPC.type;
|
||||
BannerItem = ModContent.ItemType<BabyCannonballJellyfishBanner>();
|
||||
//NPC.catchItem = (short)ModContent.ItemType<BabyCannonballJellyfishItem>();
|
||||
NPC.catchItem = (short)ModContent.ItemType<BabyCannonballJellyfishItem>();
|
||||
NPC.Calamity().VulnerableToHeat = false;
|
||||
NPC.Calamity().VulnerableToSickness = false;
|
||||
NPC.Calamity().VulnerableToElectricity = true;
|
||||
|
||||
@@ -0,0 +1,63 @@
|
||||
using CalamityMod.Items.Placeables.Furniture;
|
||||
using Microsoft.Xna.Framework;
|
||||
using Terraria;
|
||||
using Terraria.ID;
|
||||
using Terraria.ModLoader;
|
||||
using Terraria.ObjectData;
|
||||
|
||||
namespace CalamityMod.Tiles.Furniture
|
||||
{
|
||||
public class BabyCannonballJellyfishBowlTile : ModTile
|
||||
{
|
||||
public override void SetStaticDefaults()
|
||||
{
|
||||
Main.tileLighted[Type] = true;
|
||||
Main.tileFrameImportant[Type] = true;
|
||||
Main.tileLavaDeath[Type] = true;
|
||||
TileObjectData.newTile.CopyFrom(TileObjectData.Style2x2);
|
||||
TileObjectData.addTile(Type);
|
||||
AnimationFrameHeight = 36;
|
||||
AddMapEntry(new Color(64, 224, 208), CalamityUtils.GetItemName<BabyCannonballJellyfishBowl>());
|
||||
AddToArray(ref TileID.Sets.RoomNeeds.CountsAsTorch);
|
||||
}
|
||||
|
||||
public override bool CreateDust(int i, int j, ref int type)
|
||||
{
|
||||
Dust.NewDust(new Vector2(i, j) * 16f, 16, 16, 13, 0f, 0f, 0, new Color(), 1f);
|
||||
return false;
|
||||
}
|
||||
|
||||
public override void NumDust(int i, int j, bool fail, ref int num)
|
||||
{
|
||||
num = fail ? 1 : 3;
|
||||
}
|
||||
|
||||
public override void AnimateTile(ref int frame, ref int frameCounter)
|
||||
{
|
||||
int frameAmt = 8;
|
||||
int timeNeeded = 10;
|
||||
frameCounter++;
|
||||
if (frameCounter >= timeNeeded)
|
||||
{
|
||||
frame++;
|
||||
frameCounter = 0;
|
||||
}
|
||||
if (frame >= frameAmt)
|
||||
{
|
||||
frame = 0;
|
||||
}
|
||||
}
|
||||
|
||||
public override void AnimateIndividualTile(int type, int i, int j, ref int frameXOffset, ref int frameYOffset)
|
||||
{
|
||||
frameYOffset = this.GetAnimationOffset(i, j, 8, 18, 18, 2, 2, AnimationFrameHeight);
|
||||
}
|
||||
|
||||
public override void ModifyLight(int i, int j, ref float r, ref float g, ref float b)
|
||||
{
|
||||
r = 0.26f;
|
||||
g = 0.85f;
|
||||
b = 0.65f;
|
||||
}
|
||||
}
|
||||
}
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 3.0 KiB |
Reference in new issue
Block a user