@@ -29,13 +29,13 @@
#include "tunnelbridge_map.h"
#include "station_base.h"
#include "ai/ai.hpp"
#include "game/game.hpp"
#include "core/random_func.hpp"
#include "core/backup_type.hpp"
#include "date_func.h"
#include "timer/timer_game_calendar.h"
#include "company_base.h"
#include "company_gui.h"
#include "newgrf_generic.h"
#include "industry.h"
#include "water_cmd.h"
#include "landscape_cmd.h"
@@ -131,13 +131,13 @@ CommandCost CmdBuildShipDepot(DoCommandF
if (add_cost) {
cost.AddCost(ret);
}
if (flags & DC_EXEC) {
Depot *depot = new Depot(tile);
depot->build_date = _date;
depot->build_date = TimerGameCalendar::date;
uint new_water_infra = 2 * LOCK_DEPOT_TILE_FACTOR;
/* Update infrastructure counts after the tile clears earlier.
* Clearing object tiles may result in water tiles which are already accounted for in the water infrastructure total.
* See: MakeWaterKeepingClass() */
if (wc1 == WATER_CLASS_CANAL && !(HasTileWaterClass(tile) && GetWaterClass(tile) == WATER_CLASS_CANAL && IsTileOwner(tile, _current_company))) new_water_infra++;