mirror of
https://github.com/JGRennison/OpenTTD-patches.git
synced 2024-11-19 15:25:39 +00:00
(svn r16529) -Fix [NoAI]: StationIDs from oilrigs were not considered valid by the API.
This commit is contained in:
parent
8745a30971
commit
726ba50868
@ -18,7 +18,7 @@
|
|||||||
/* static */ bool AIStation::IsValidStation(StationID station_id)
|
/* static */ bool AIStation::IsValidStation(StationID station_id)
|
||||||
{
|
{
|
||||||
const Station *st = ::Station::GetIfValid(station_id);
|
const Station *st = ::Station::GetIfValid(station_id);
|
||||||
return st != NULL && st->owner == _current_company;
|
return st != NULL && (st->owner == _current_company || st->owner == OWNER_NONE);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* static */ StationID AIStation::GetStationID(TileIndex tile)
|
/* static */ StationID AIStation::GetStationID(TileIndex tile)
|
||||||
|
Loading…
Reference in New Issue
Block a user