Definition at line 61922 of file Main.cs.
61923 {
61925 {
61928 }
61930 {
61932 }
61933 NPC.ResetBadgerHatTime();
61934 NPC.freeCake = false;
61936 NPC.setFireFlyChance();
61939 WorldGen.mysticLogsEvent.StartNight();
61940 WorldGen.prioritizedTownNPCType = 0;
61943 {
61944 WorldGen.spawnMeteor = true;
61945 }
61947 {
61949 }
61951 {
61953 }
61956 {
61958 }
61960 {
61962 {
61963 bool flag = false;
61964 for (
int i = 0;
i < 255;
i++)
61965 {
61967 {
61968 flag = true;
61969 break;
61970 }
61971 }
61972 if (flag &&
rand.Next(3) == 0)
61973 {
61974 int num = 0;
61975 for (
int j = 0;
j < 200;
j++)
61976 {
61977 if (
npc[
j].active &&
npc[
j].townNPC)
61978 {
61979 num++;
61980 }
61981 }
61982 if (num >= 4)
61983 {
61984 WorldGen.spawnEye = true;
61986 {
61987 NewText(Lang.misc[9].Value, 50,
byte.MaxValue, 130);
61988 }
61990 {
61992 }
61993 }
61994 }
61995 }
61997 {
61998 bool flag2 =
false;
61999 for (
int k = 0;
k < 200;
k++)
62000 {
62002 {
62004 }
62005 }
62006 if (!
flag2 && (!
NPC.downedMechBoss1 || !
NPC.downedMechBoss2 || !
NPC.downedMechBoss3))
62007 {
62009 {
62010 if (
rand.Next(2) == 0)
62011 {
62012 WorldGen.spawnHardBoss =
rand.Next(3) + 1;
62014 {
62015 NewText(Lang.misc[108].Value, 50,
byte.MaxValue, 130);
62016 }
62018 {
62020 }
62021 }
62022 }
62023 else
62024 {
62025 for (
int l = 0;
l < 1000;
l++)
62026 {
62028 if (
num2 == 1 && !
NPC.downedMechBoss1)
62029 {
62030 WorldGen.spawnHardBoss =
num2;
62032 {
62033 NewText(Lang.misc[28].Value, 50,
byte.MaxValue, 130);
62034 }
62036 {
62038 }
62039 break;
62040 }
62041 if (
num2 == 2 && !
NPC.downedMechBoss2)
62042 {
62043 WorldGen.spawnHardBoss =
num2;
62045 {
62046 NewText(Lang.misc[29].Value, 50,
byte.MaxValue, 130);
62047 }
62049 {
62051 }
62052 break;
62053 }
62054 if (
num2 == 3 && !
NPC.downedMechBoss3)
62055 {
62056 WorldGen.spawnHardBoss =
num2;
62058 {
62059 NewText(Lang.misc[30].Value, 50,
byte.MaxValue, 130);
62060 }
62062 {
62064 }
62065 break;
62066 }
62067 }
62068 }
62069 }
62070 }
62073 {
62075 }
62077 {
62078 for (
int m = 0;
m < 255;
m++)
62079 {
62081 {
62083 break;
62084 }
62085 }
62087 {
62092 {
62093 NewText(Lang.misc[8].Value, 50,
byte.MaxValue, 130);
62094 }
62096 {
62098 }
62099 }
62100 }
62101 }
62105 {
62106 NetMessage.SendData(7);
62107 }
62108 }
static void BroadcastChatMessage(NetworkText text, Color color, int excludedPlayer=-1)
static void NotifyProgressionEvent(int eventID)
static int checkForSpawns
static bool IsFastForwardingTime()
static void NewText(string newText, byte R=byte.MaxValue, byte G=byte.MaxValue, byte B=byte.MaxValue)
static int moondialCooldown
static UnifiedRandom rand
static void UpdateTimeRate()
static bool tenthAnniversaryWorld
static int sundialCooldown
static bool fastForwardTimeToDusk
References Terraria.WorldGen.altarCount, Terraria.Main.bloodMoon, Terraria.Chat.ChatHelper.BroadcastChatMessage(), Terraria.Main.checkForSpawns, Terraria.GameContent.Events.BirthdayParty.CheckNight(), Terraria.GameContent.Events.LanternNight.CheckNight(), Terraria.Main.dayTime, Terraria.NPC.downedBoss1, Terraria.NPC.downedBoss2, Terraria.NPC.downedMechBoss1, Terraria.NPC.downedMechBoss2, Terraria.NPC.downedMechBoss3, Terraria.Main.eclipse, Terraria.Main.fastForwardTimeToDusk, Terraria.Main.getGoodWorld, Terraria.Main.hardMode, System.Text.RegularExpressions.i, Terraria.Main.IsFastForwardingTime(), Terraria.GameContent.Events.LanternNight.LanternsUp, Terraria.Lang.misc, Terraria.Main.moondialCooldown, Terraria.Main.moonPhase, Terraria.WorldGen.mysticLogsEvent, Terraria.Main.netMode, Terraria.Main.NewText(), Terraria.Star.NightSetup(), Terraria.GameContent.Achievements.AchievementsHelper.NotifyProgressionEvent(), Terraria.Main.npc, Terraria.GameContent.Events.DD2Event.Ongoing, Terraria.Main.player, Terraria.Main.pumpkinMoon, Terraria.Main.rand, Terraria.Main.remixWorld, Terraria.NPC.ResetBadgerHatTime(), Terraria.NetMessage.SendData(), Terraria.NPC.setFireFlyChance(), Terraria.Main.snowMoon, Terraria.WorldGen.spawnEye, Terraria.Main.sundialCooldown, Terraria.Main.tenthAnniversaryWorld, Terraria.Main.time, and Terraria.Main.UpdateTimeRate().
Referenced by Terraria.Main.SkipToTime(), and Terraria.Main.UpdateTime().