35 std::unordered_map<uint32, WeatherData> _weatherData;
50 "zone, spring_rain_chance, spring_snow_chance, spring_storm_chance,"
51 "summer_rain_chance, summer_snow_chance, summer_storm_chance,"
52 "fall_rain_chance, fall_snow_chance, fall_storm_chance,"
53 "winter_rain_chance, winter_snow_chance, winter_storm_chance,"
54 "ScriptName FROM game_weather");
58 TC_LOG_INFO(
"server.loading",
">> Loaded 0 weather definitions. DB table `game_weather` is empty.");
64 Field* fields = result->Fetch();
79 TC_LOG_ERROR(
"sql.sql",
"Weather for zone {} season {} has wrong rain chance > 100%", zone_id, season);
85 TC_LOG_ERROR(
"sql.sql",
"Weather for zone {} season {} has wrong snow chance > 100%", zone_id, season);
91 TC_LOG_ERROR(
"sql.sql",
"Weather for zone {} season {} has wrong storm chance > 100%", zone_id, season);
99 while (result->NextRow());
std::shared_ptr< ResultSet > QueryResult
DatabaseWorkerPool< WorldDatabaseConnection > WorldDatabase
Accessor to the world database.
#define TC_LOG_ERROR(filterType__,...)
#define TC_LOG_INFO(filterType__,...)
uint32 GetMSTimeDiffToNow(uint32 oldMSTime)
Class used to access individual fields of database query result.
WeatherSeasonChances data[WEATHER_SEASONS]
WeatherData const * GetWeatherData(uint32 zone_id)
auto MapGetValuePtr(M &map, typename M::key_type const &key)