feat: coal tile

This commit is contained in:
Abdulmujeeb Raji 2024-11-12 11:48:36 +00:00
parent 53f61ab431
commit 58e0970ccf
Signed by untrusted user: midnadimple
GPG key ID: EB02C582F8C3962B
9 changed files with 64 additions and 3 deletions

View file

@ -0,0 +1,18 @@
using continuity.Content.Tiles;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Terraria.ModLoader;
namespace continuity.Content.Items.Materials
{
public class Coal : ModItem
{
public override void SetDefaults()
{
Item.DefaultToPlaceableTile(ModContent.TileType<CoalTile>());
}
}
}

View file

@ -2,7 +2,7 @@ using Terraria;
using Terraria.ID;
using Terraria.ModLoader;
namespace Continuity.Content.Items
namespace Continuity.Content.Items.Materials
{
public class ExquisiteGel : ModItem
{

View file

@ -2,7 +2,7 @@ using Terraria;
using Terraria.ID;
using Terraria.ModLoader;
namespace Continuity.Content.Items
namespace Continuity.Content.Items.Materials
{
public class PalishadeTissue : ModItem
{

View file

@ -1,4 +1,5 @@
using Continuity.Content.Items;
using Continuity.Content.Items.Materials;
using Microsoft.Xna.Framework;
using System;
using System.Collections.Generic;
@ -9,7 +10,7 @@ using Terraria;
using Terraria.ID;
using Terraria.ModLoader;
namespace continuity.Content.Items
namespace continuity.Content.Items.Weapons
{
public class Geltana : ModItem
{

View file

@ -5,6 +5,7 @@ using Terraria.ID;
using Terraria.ModLoader;
using Terraria.GameContent.ItemDropRules;
using Continuity.Content.Items;
using Continuity.Content.Items.Materials;
namespace Continuity.Content
{

View file

@ -2,6 +2,7 @@ using Terraria;
using Terraria.ID;
using Terraria.ModLoader;
using Continuity.Content.Items;
using Continuity.Content.Items.Materials;
namespace Continuity.Content
{

33
Content/Tiles/CoalTile.cs Normal file
View file

@ -0,0 +1,33 @@
using Microsoft.Xna.Framework;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Terraria;
using Terraria.ID;
using Terraria.Localization;
using Terraria.ModLoader;
namespace continuity.Content.Tiles
{
public class CoalTile : ModTile
{
public override void SetStaticDefaults()
{
TileID.Sets.Ore[Type] = true;
Main.tileSpelunker[Type] = true; // The tile will be affected by spelunker highlighting
Main.tileMergeDirt[Type] = true;
Main.tileSolid[Type] = true;
Main.tileBlockLight[Type] = true;
Main.tileLavaDeath[Type] = true;
LocalizedText name = CreateMapEntryName();
AddMapEntry(new Color(55, 51, 52), name);
DustType = 84;
HitSound = SoundID.Tink;
}
}
}

View file

Before

Width:  |  Height:  |  Size: 8.8 KiB

After

Width:  |  Height:  |  Size: 8.8 KiB

View file

@ -21,4 +21,11 @@ Items: {
'''
DisplayName: Geltana
}
Coal: {
DisplayName: Coal
Tooltip: ""
}
}
Tiles.CoalTile.MapEntry: Coal Tile