(svn r17113) -Change [FS#265][FS#2094][FS#2589]: apply the subsidy when subsidy's destination is in station's catchment area and cargo packets originate from subsidy's source

-Change [FS#1134]: subsidies aren't bound to stations after awarding anymore, they still apply to town or industry, no matter what station is used for loading and unloading. Awarded subsidies from older savegames are lost
-Change [NoAI]: due to these changes, AISubsidy::GetSource and AISubsidy::GetDestination now return STATION_INVALID for awarded subsidies
This commit is contained in:
smatz
2009-08-08 16:42:55 +00:00
parent eb5039f81e
commit 0502a6df42
29 changed files with 312 additions and 180 deletions

View File

@@ -20,6 +20,7 @@
#include "map_type.h"
#include "command_type.h"
#include "town_map.h"
#include "subsidy_type.h"
template <typename T>
struct BuildingCounts {
@@ -107,6 +108,8 @@ struct Town : TownPool::PoolItem<&_town_pool> {
bool larger_town;
TownLayoutByte layout; ///< town specific road layout
PartOfSubsidyByte part_of_subsidy; ///< NOSAVE: is this town a source/destination of a subsidy?
/* NOSAVE: UpdateTownRadius updates this given the house count. */
uint32 squared_town_zone_radius[HZB_END];