Codechange: Move calendar date functions inside TimerGameCalendar (#10753)
This commit is contained in:
@@ -13,7 +13,6 @@
|
||||
#include "game_info.h"
|
||||
#include "../../core/bitmath_func.hpp"
|
||||
#include "../../company_base.h"
|
||||
#include "../../date_func.h"
|
||||
#include "../../timer/timer_game_calendar.h"
|
||||
#include "../../debug.h"
|
||||
#include "../../map_func.h"
|
||||
@@ -124,7 +123,7 @@ void CheckGameCompatibility(NetworkGameInfo &ngi)
|
||||
void FillStaticNetworkServerGameInfo()
|
||||
{
|
||||
_network_game_info.use_password = !_settings_client.network.server_password.empty();
|
||||
_network_game_info.start_date = ConvertYMDToDate(_settings_game.game_creation.starting_year, 0, 1);
|
||||
_network_game_info.start_date = TimerGameCalendar::ConvertYMDToDate(_settings_game.game_creation.starting_year, 0, 1);
|
||||
_network_game_info.clients_max = _settings_client.network.max_clients;
|
||||
_network_game_info.companies_max = _settings_client.network.max_companies;
|
||||
_network_game_info.map_width = Map::SizeX();
|
||||
@@ -256,7 +255,7 @@ void SerializeNetworkGameInfo(Packet *p, const NetworkServerGameInfo *info, bool
|
||||
*/
|
||||
void DeserializeNetworkGameInfo(Packet *p, NetworkGameInfo *info, const GameInfoNewGRFLookupTable *newgrf_lookup_table)
|
||||
{
|
||||
static const TimerGameCalendar::Date MAX_DATE = ConvertYMDToDate(MAX_YEAR, 11, 31); // December is month 11
|
||||
static const TimerGameCalendar::Date MAX_DATE = TimerGameCalendar::ConvertYMDToDate(MAX_YEAR, 11, 31); // December is month 11
|
||||
|
||||
byte game_info_version = p->Recv_uint8();
|
||||
NewGRFSerializationType newgrf_serialisation = NST_GRFID_MD5;
|
||||
|
@@ -10,7 +10,7 @@
|
||||
*/
|
||||
|
||||
#include "../../stdafx.h"
|
||||
#include "../../date_func.h"
|
||||
#include "../../timer/timer_game_calendar.h"
|
||||
#include "../../debug.h"
|
||||
#include "tcp_coordinator.h"
|
||||
|
||||
|
@@ -10,7 +10,7 @@
|
||||
*/
|
||||
|
||||
#include "../../stdafx.h"
|
||||
#include "../../date_func.h"
|
||||
#include "../../timer/timer_game_calendar.h"
|
||||
#include "../../debug.h"
|
||||
#include "tcp_turn.h"
|
||||
|
||||
|
@@ -10,7 +10,7 @@
|
||||
*/
|
||||
|
||||
#include "../../stdafx.h"
|
||||
#include "../../date_func.h"
|
||||
#include "../../timer/timer_game_calendar.h"
|
||||
#include "../../debug.h"
|
||||
#include "game_info.h"
|
||||
#include "udp.h"
|
||||
|
Reference in New Issue
Block a user