49 lines
1.4 KiB
C#
49 lines
1.4 KiB
C#
using CalamityMod.Dusts;
|
|
using CalamityMod.Items.Materials;
|
|
using Microsoft.Xna.Framework;
|
|
using Terraria;
|
|
using Terraria.ModLoader;
|
|
using Terraria.ObjectData;
|
|
|
|
namespace CalamityMod.Tiles
|
|
{
|
|
public class ShadowspecBarTile : ModTile
|
|
{
|
|
public override void SetDefaults()
|
|
{
|
|
Main.tileShine[Type] = 1000;
|
|
Main.tileSolid[Type] = true;
|
|
Main.tileSolidTop[Type] = true;
|
|
Main.tileFrameImportant[Type] = true;
|
|
|
|
TileObjectData.newTile.CopyFrom(TileObjectData.Style1x1);
|
|
TileObjectData.newTile.StyleHorizontal = true;
|
|
TileObjectData.newTile.LavaDeath = false;
|
|
TileObjectData.addTile(Type);
|
|
|
|
dustType = ModContent.DustType<ShadowspecBarDust>();
|
|
drop = ModContent.ItemType<ShadowspecBar>();
|
|
|
|
AddMapEntry(new Color(128, 41, 149));
|
|
}
|
|
|
|
public override bool CreateDust(int i, int j, ref int type)
|
|
{
|
|
type = ModContent.DustType<ShadowspecBarDust>();
|
|
return true;
|
|
}
|
|
|
|
public override bool TileFrame(int i, int j, ref bool resetFrame, ref bool noBreak)
|
|
{
|
|
WorldGen.Check1x1(i, j, Type);
|
|
return true;
|
|
}
|
|
|
|
public override void PlaceInWorld(int i, int j, Item item)
|
|
{
|
|
Main.tile[i, j].frameX = 0;
|
|
Main.tile[i, j].frameY = 0;
|
|
}
|
|
}
|
|
}
|