placed alpha minnows no longer spawn shoals

This commit is contained in:
GinYuH authored and Cameron Ewell committed 2024-07-30 18:27:16 -04:00
1 parent 6b59c9e0be
commit c6ed1ad1e3
1 file changed
+6
+6
View File
@@ -50,6 +50,12 @@ namespace CalamityMod.NPCs.SunkenSea
public override void OnSpawn(IEntitySource source)
{
// Alphas released by the player do not spawn a shoal of minnows
if (source is EntitySource_Parent parentSource && parentSource.Entity is Player)
{
return;
}
// Spawn a shoal of minnows
int fishCount = Main.rand.Next(5, 10);
for (int i = 0; i < fishCount; i++)
{