Basalt Gully ModBiome & Steampod bestiary fix
This commit is contained in:
1 parent
84682c5f93
commit
d44d1a6799
4 files changed
+28
-5
No files matched your search
@@ -1,9 +1,29 @@
|
||||
using Terraria.ModLoader;
|
||||
using CalamityMod.Systems;
|
||||
using CalamityMod.Waters;
|
||||
using Terraria.ID;
|
||||
using Terraria;
|
||||
using Terraria.ModLoader;
|
||||
using CalamityMod.Items.Placeables.Furniture;
|
||||
|
||||
namespace CalamityMod.BiomeManagers
|
||||
{
|
||||
public class BasaltGullyBiome : ModBiome
|
||||
{
|
||||
public override ModWaterStyle WaterStyle => SunkenSeaBurrowsWater.Instance;
|
||||
public override ModUndergroundBackgroundStyle UndergroundBackgroundStyle => ModContent.Find<ModUndergroundBackgroundStyle>("CalamityMod/SunkenSeaBGStyle");
|
||||
public override int BiomeTorchItemType => ModContent.ItemType<NavyPrismTorch>();
|
||||
public override int Music => CalamityMod.Instance.GetMusicFromMusicMod("SunkenSea") ?? MusicID.OceanNight;
|
||||
public override SceneEffectPriority Priority => SceneEffectPriority.Environment;
|
||||
public override string BestiaryIcon => "CalamityMod/BiomeManagers/SunkenSeaIcon";
|
||||
// Placeholder until we get a dedicated Basalt Gully background
|
||||
public override string BackgroundPath => "Terraria/Images/MapBG3";
|
||||
public override string MapBackground => "Terraria/Images/MapBG3";
|
||||
|
||||
public override bool IsBiomeActive(Player player)
|
||||
{
|
||||
bool MoreThanBurrows = BiomeTileCounterSystem.SunkenSeaBasaltTiles > BiomeTileCounterSystem.SunkenSeaBurrowsTiles;
|
||||
|
||||
return BiomeTileCounterSystem.SunkenSeaBasaltTiles > 1000 && MoreThanBurrows;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -7191,8 +7191,8 @@ namespace CalamityMod.NPCs
|
||||
continue;
|
||||
|
||||
WeightedRandom<int> pool = new WeightedRandom<int>();
|
||||
pool.Add(NPCID.None, 0f);
|
||||
pool.Add(NPCType<PodobooKoi>(), 0.25f);
|
||||
pool.Add(NPCID.None, 1f);
|
||||
pool.Add(NPCType<PodobooKoi>(), 0.05f);
|
||||
|
||||
int typeToSpawn = pool.Get();
|
||||
if (typeToSpawn != NPCID.None)
|
||||
|
||||
@@ -494,8 +494,8 @@ namespace CalamityMod.NPCs.SunkenSea
|
||||
public override bool PreDraw(SpriteBatch spriteBatch, Vector2 screenPos, Color drawColor)
|
||||
{
|
||||
Texture2D tex = TextureAssets.Npc[NPC.type].Value;
|
||||
spriteBatch.Draw(tex, NPC.Center - Main.screenPosition + Vector2.UnitY * NPC.gfxOffY, NPC.frame, NPC.GetAlpha(drawColor), NPC.rotation, new Vector2(tex.Width / 2, tex.Height / 2 / Main.npcFrameCount[NPC.type]), NPC.scale, NPC.spriteDirection == 1 ? SpriteEffects.FlipHorizontally : 0, 0);
|
||||
spriteBatch.Draw(glowTex.Value, NPC.Center - Main.screenPosition + Vector2.UnitY * NPC.gfxOffY, NPC.frame, Color.White, NPC.rotation, new Vector2(tex.Width / 2, tex.Height / 2 / Main.npcFrameCount[NPC.type]), NPC.scale, NPC.spriteDirection == 1 ? SpriteEffects.FlipHorizontally : 0, 0);
|
||||
spriteBatch.Draw(tex, NPC.Center - screenPos + Vector2.UnitY * NPC.gfxOffY, NPC.frame, NPC.GetAlpha(drawColor), NPC.rotation, new Vector2(tex.Width / 2, tex.Height / 2 / Main.npcFrameCount[NPC.type]), NPC.scale, NPC.spriteDirection == 1 ? SpriteEffects.FlipHorizontally : 0, 0);
|
||||
spriteBatch.Draw(glowTex.Value, NPC.Center - screenPos + Vector2.UnitY * NPC.gfxOffY, NPC.frame, Color.White, NPC.rotation, new Vector2(tex.Width / 2, tex.Height / 2 / Main.npcFrameCount[NPC.type]), NPC.scale, NPC.spriteDirection == 1 ? SpriteEffects.FlipHorizontally : 0, 0);
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -23,6 +23,7 @@ namespace CalamityMod.Systems
|
||||
public static int SunkenSeaPolypTiles = 0;
|
||||
public static int SunkenSeaReefsTiles = 0;
|
||||
public static int SunkenSeaBurrowsTiles = 0;
|
||||
public static int SunkenSeaBasaltTiles = 0;
|
||||
public static int ArsenalLabTiles = 0;
|
||||
public static int AbyssTiles = 0;
|
||||
public static int FloralParadiseTiles = 0;
|
||||
@@ -41,6 +42,7 @@ namespace CalamityMod.Systems
|
||||
SunkenSeaPolypTiles = 0;
|
||||
SunkenSeaReefsTiles = 0;
|
||||
SunkenSeaBurrowsTiles = 0;
|
||||
SunkenSeaBasaltTiles = 0;
|
||||
SulphurTiles = 0;
|
||||
AbyssTiles = 0;
|
||||
ArsenalLabTiles = 0;
|
||||
@@ -60,6 +62,7 @@ namespace CalamityMod.Systems
|
||||
SunkenSeaPolypTiles = tileCounts[ModContent.TileType<Limestone>()] + tileCounts[ModContent.TileType<PolypSand>()];
|
||||
SunkenSeaReefsTiles = tileCounts[ModContent.TileType<Shellstone>()] + tileCounts[ModContent.TileType<EutrophicSand>()] + tileCounts[ModContent.TileType<YellowCoral>()] + tileCounts[ModContent.TileType<OrangeCoral>()] + tileCounts[ModContent.TileType<CyanCoral>()] + tileCounts[ModContent.TileType<LimeCoral>()] + tileCounts[ModContent.TileType<MagentaCoral>()];
|
||||
SunkenSeaBurrowsTiles = tileCounts[ModContent.TileType<Navystone>()] + tileCounts[ModContent.TileType<HardenedEutrophicSand>()];
|
||||
SunkenSeaBasaltTiles = tileCounts[ModContent.TileType<Basalt>()] + tileCounts[ModContent.TileType<VolcanicSand>()];
|
||||
AbyssTiles = tileCounts[ModContent.TileType<AbyssGravel>()] + tileCounts[ModContent.TileType<Voidstone>()];
|
||||
SulphurTiles = tileCounts[ModContent.TileType<SulphurousSand>()] + tileCounts[ModContent.TileType<SulphurousSandstone>()] + tileCounts[ModContent.TileType<HardenedSulphurousSandstone>()];
|
||||
FloralParadiseTiles = tileCounts[ModContent.TileType<AlgalSlate>()] + tileCounts[ModContent.TileType<PeatMoss>()] + tileCounts[ModContent.TileType<Peat>()];
|
||||
|
||||
Reference in new issue
Block a user