PlantyMush piles

This commit is contained in:
Heart-Plus-Up committed 2023-02-13 08:03:04 -07:00
1 parent c45e843497
commit a8cea8cd68
8 files changed
+76 -9

No files matched your search

+3 -3
View File
@@ -51,9 +51,9 @@ namespace CalamityMod.Tiles.Abyss.AbyssAmbient
Tile tile = Framing.GetTileSafely(i, j);
if (tile.TileFrameY <= 36)
{
r = 233f / 255f;
g = 144f / 255f;
b = 30f / 255f;
r = 184f / 255f;
g = 90f / 255f;
b = 20f / 255f;
}
}
+3 -3
View File
@@ -40,9 +40,9 @@ namespace CalamityMod.Tiles.Abyss.AbyssAmbient
Tile tile = Framing.GetTileSafely(i, j);
if (tile.TileFrameY <= 36)
{
r = 233f / 255f;
g = 144f / 255f;
b = 30f / 255f;
r = 184f / 400f;
g = 90f / 400f;
b = 20f / 400f;
}
}
public override void NearbyEffects(int i, int j, bool closer)
+3 -3
View File
@@ -40,9 +40,9 @@ namespace CalamityMod.Tiles.Abyss.AbyssAmbient
Tile tile = Framing.GetTileSafely(i, j);
if (tile.TileFrameY <= 36)
{
r = 233f / 255f;
g = 144f / 255f;
b = 30f / 255f;
r = 184f / 300f;
g = 90f / 300f;
b = 20f / 300f;
}
}
public override void NearbyEffects(int i, int j, bool closer)
@@ -0,0 +1,49 @@
using CalamityMod.Dusts;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;
using Terraria;
using Terraria.DataStructures;
using Terraria.Enums;
using Terraria.ModLoader;
using Terraria.ObjectData;
namespace CalamityMod.Tiles.Abyss.AbyssAmbient
{
public class PlantyMushPile1 : ModTile
{
public override void SetStaticDefaults()
{
Main.tileLighted[Type] = true;
Main.tileFrameImportant[Type] = true;
TileObjectData.newTile.Width = 3;
TileObjectData.newTile.Height = 2;
TileObjectData.newTile.Origin = new Point16(1, 1);
TileObjectData.newTile.AnchorBottom = new AnchorData(AnchorType.SolidTile | AnchorType.SolidWithTop | AnchorType.Table | AnchorType.SolidSide, TileObjectData.newTile.Width, 0);
TileObjectData.newTile.UsesCustomCanPlace = true;
TileObjectData.newTile.CoordinateHeights = new int[] { 16, 16 };
TileObjectData.newTile.CoordinateWidth = 16;
TileObjectData.newTile.CoordinatePadding = 2;
TileObjectData.newTile.WaterDeath = false;
TileObjectData.newTile.LavaDeath = true;
TileObjectData.newTile.DrawYOffset = 2;
TileObjectData.addTile(Type);
AddMapEntry(new Color(84, 102, 39));
DustType = 33;
base.SetStaticDefaults();
}
public override void NumDust(int i, int j, bool fail, ref int num)
{
num = fail ? 1 : 2;
}
}
public class PlantyMushPile2 : PlantyMushPile1
{
}
public class PlantyMushPile3 : PlantyMushPile1
{
}
}
Binary file not shown.

After

Width:  |  Height:  |  Size: 593 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 587 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 611 B

+18
View File
@@ -606,6 +606,17 @@ namespace CalamityMod.World
WorldGen.PlaceObject(abyssIndex, abyssIndex2, WorldGen.genRand.Next(Ribs));
}
}
//PlantyMush
if (tile.TileType == ModContent.TileType<PlantyMush>())
{
if (WorldGen.genRand.NextBool(8))
{
ushort[] PlantPiles = new ushort[] { (ushort)ModContent.TileType<PlantyMushPile1>(),
(ushort)ModContent.TileType<PlantyMushPile2>(), (ushort)ModContent.TileType<PlantyMushPile3>() };
WorldGen.PlaceObject(abyssIndex, abyssIndex2, WorldGen.genRand.Next(PlantPiles));
}
}
//abyss gravel stuff
if (tile.TileType == ModContent.TileType<AbyssGravel>())
@@ -618,6 +629,13 @@ namespace CalamityMod.World
WorldGen.PlaceObject(abyssIndex, abyssIndex2, WorldGen.genRand.Next(Kelps));
}
if (WorldGen.genRand.NextBool(40))
{
ushort[] PlantPiles = new ushort[] { (ushort)ModContent.TileType<PlantyMushPile1>(),
(ushort)ModContent.TileType<PlantyMushPile2>(), (ushort)ModContent.TileType<PlantyMushPile3>() };
WorldGen.PlaceObject(abyssIndex, abyssIndex2, WorldGen.genRand.Next(PlantPiles));
}
//gravel rock piles
if (WorldGen.genRand.NextBool(15))