Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ AmbienceServer()

Terraria.GameContent.Ambience.AmbienceServer.AmbienceServer ( )
inline

Definition at line 57 of file AmbienceServer.cs.

58 {
60 _spawnConditions[SkyEntityType.BirdsV] = IsSunnyDay;
61 _spawnConditions[SkyEntityType.Wyvern] = () => IsSunnyDay() && Main.hardMode;
62 _spawnConditions[SkyEntityType.Airship] = () => IsSunnyDay() && Main.IsItAHappyWindyDay;
63 _spawnConditions[SkyEntityType.AirBalloon] = () => IsSunnyDay() && !Main.IsItAHappyWindyDay;
64 _spawnConditions[SkyEntityType.Eyeball] = () => !Main.dayTime;
65 _spawnConditions[SkyEntityType.Butterflies] = () => IsSunnyDay() && !Main.IsItAHappyWindyDay && !NPC.TooWindyForButterflies && NPC.butterflyChance < 6;
66 _spawnConditions[SkyEntityType.LostKite] = () => Main.dayTime && !Main.eclipse && Main.IsItAHappyWindyDay;
67 _spawnConditions[SkyEntityType.Vulture] = () => IsSunnyDay();
68 _spawnConditions[SkyEntityType.Bats] = () => (IsSunset() && IsSunnyDay()) || IsCalmNight();
69 _spawnConditions[SkyEntityType.PixiePosse] = () => IsSunnyDay() || IsCalmNight();
70 _spawnConditions[SkyEntityType.Seagulls] = () => IsSunnyDay();
71 _spawnConditions[SkyEntityType.SlimeBalloons] = () => IsSunnyDay() && Main.IsItAHappyWindyDay;
72 _spawnConditions[SkyEntityType.Gastropods] = () => IsCalmNight();
73 _spawnConditions[SkyEntityType.Pegasus] = () => IsSunnyDay();
74 _spawnConditions[SkyEntityType.EaterOfSouls] = () => IsSunnyDay() || IsCalmNight();
75 _spawnConditions[SkyEntityType.Crimera] = () => IsSunnyDay() || IsCalmNight();
76 _spawnConditions[SkyEntityType.Hellbats] = () => true;
77 _secondarySpawnConditionsPerPlayer[SkyEntityType.Vulture] = (Player player) => player.ZoneDesert;
78 _secondarySpawnConditionsPerPlayer[SkyEntityType.PixiePosse] = (Player player) => player.ZoneHallow;
79 _secondarySpawnConditionsPerPlayer[SkyEntityType.Seagulls] = (Player player) => player.ZoneBeach;
80 _secondarySpawnConditionsPerPlayer[SkyEntityType.Gastropods] = (Player player) => player.ZoneHallow;
81 _secondarySpawnConditionsPerPlayer[SkyEntityType.Pegasus] = (Player player) => player.ZoneHallow;
82 _secondarySpawnConditionsPerPlayer[SkyEntityType.EaterOfSouls] = (Player player) => player.ZoneCorrupt;
83 _secondarySpawnConditionsPerPlayer[SkyEntityType.Crimera] = (Player player) => player.ZoneCrimson;
84 _secondarySpawnConditionsPerPlayer[SkyEntityType.Bats] = (Player player) => player.ZoneJungle;
85 }
readonly Dictionary< SkyEntityType, Func< Player, bool > > _secondarySpawnConditionsPerPlayer
readonly Dictionary< SkyEntityType, Func< bool > > _spawnConditions

References Terraria.GameContent.Ambience.AmbienceServer._secondarySpawnConditionsPerPlayer, Terraria.GameContent.Ambience.AmbienceServer._spawnConditions, Terraria.Main.dayTime, Terraria.Main.eclipse, Terraria.Main.hardMode, Terraria.GameContent.Ambience.AmbienceServer.IsCalmNight(), Terraria.Main.IsItAHappyWindyDay, Terraria.GameContent.Ambience.AmbienceServer.IsSunnyDay(), Terraria.GameContent.Ambience.AmbienceServer.IsSunset(), and Terraria.GameContent.Ambience.AmbienceServer.ResetSpawnTime().