83 {
84 int year, month, day, hour, minute;
85 GetGame().GetWorld().GetDate(year, month, day, hour, minute);
86
87
88 int now = hour * 60 + minute;
89
90 foreach (BunkerBroadcastPeriod period :
m_Config.schedulerSettings.periods)
91 {
92 int start = period.GetStartHour() * 60 + period.GetStartMinute();
93 int end = period.GetEndHour() * 60 + period.GetEndMinute();
94
95 bool active = false;
96
97 if (start < end)
98 {
99
100 active = (now >= start) && (now <= end);
101 }
102 else if (start > end)
103 {
104
105 active = (now >= start) || (now <= end);
106 }
107 else
108 {
109
110
111 active = true;
112 }
113
114 if (active)
115 {
117 return;
118 }
119 }
120
122 }
BunkerBroadcastConfigInstance m_Config