summaryrefslogtreecommitdiff
path: root/src/script/api/script_station.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/script/api/script_station.cpp')
-rw-r--r--src/script/api/script_station.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/script/api/script_station.cpp b/src/script/api/script_station.cpp
index 4ece3da04..61964c47b 100644
--- a/src/script/api/script_station.cpp
+++ b/src/script/api/script_station.cpp
@@ -23,7 +23,7 @@
/* static */ bool ScriptStation::IsValidStation(StationID station_id)
{
const Station *st = ::Station::GetIfValid(station_id);
- return st != NULL && (st->owner == _current_company || st->owner == OWNER_NONE);
+ return st != NULL && (st->owner == _current_company || _current_company == OWNER_DEITY || st->owner == OWNER_NONE);
}
/* static */ StationID ScriptStation::GetStationID(TileIndex tile)