summaryrefslogtreecommitdiff
path: root/src/station_gui.cpp
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2009-07-22 08:59:57 +0000
committerrubidium <rubidium@openttd.org>2009-07-22 08:59:57 +0000
commit68ead6b84f56ad3c93d05ad3e09b7fbb8173cf26 (patch)
treeee33bd19b96a138530a84e86e7ffd60c0700f9d9 /src/station_gui.cpp
parent2646a99d29535a44c5998f080131cbca2e85bdcf (diff)
downloadopenttd-68ead6b84f56ad3c93d05ad3e09b7fbb8173cf26.tar.xz
(svn r16909) -Fix [FS#2996]: NewGRF stations would be triggering assertions all over the place when using the more advanced station types.
-Change: make (rail) waypoints sub classes of 'base stations', make buoys waypoints and unify code between them where possible.
Diffstat (limited to 'src/station_gui.cpp')
-rw-r--r--src/station_gui.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/station_gui.cpp b/src/station_gui.cpp
index 8db32d0ae..6656428a0 100644
--- a/src/station_gui.cpp
+++ b/src/station_gui.cpp
@@ -143,7 +143,7 @@ protected:
const Station *st;
FOR_ALL_STATIONS(st) {
- if (st->owner == owner || (st->owner == OWNER_NONE && !st->IsBuoy() && HasStationInUse(st->index, owner))) {
+ if (st->owner == owner || (st->owner == OWNER_NONE && HasStationInUse(st->index, owner))) {
if (this->facilities & st->facilities) { // only stations with selected facilities
int num_waiting_cargo = 0;
for (CargoID j = 0; j < NUM_CARGO; j++) {
@@ -378,7 +378,7 @@ public:
/* Do not do the complex check HasStationInUse here, it may be even false
* when the order had been removed and the station list hasn't been removed yet */
- assert(st->owner == owner || (st->owner == OWNER_NONE && !st->IsBuoy()));
+ assert(st->owner == owner || st->owner == OWNER_NONE);
SetDParam(0, st->index);
SetDParam(1, st->facilities);
@@ -409,7 +409,7 @@ public:
const Station *st = this->stations[id_v];
/* do not check HasStationInUse - it is slow and may be invalid */
- assert(st->owner == (Owner)this->window_number || (st->owner == OWNER_NONE && !st->IsBuoy()));
+ assert(st->owner == (Owner)this->window_number || st->owner == OWNER_NONE);
if (_ctrl_pressed) {
ShowExtraViewPortWindow(st->xy);