summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorpeter1138 <peter1138@openttd.org>2006-05-06 20:27:32 +0000
committerpeter1138 <peter1138@openttd.org>2006-05-06 20:27:32 +0000
commit82037a5abecea4e1f51e76f4cbde773d6c7013f5 (patch)
tree333ccab9387187eaa69629da1084a7e8a6253d95
parent416f8ec5fb6e581d0452022604a6864c4ead1258 (diff)
downloadopenttd-82037a5abecea4e1f51e76f4cbde773d6c7013f5.tar.xz
(svn r4752) - NewGRF: brokenness slipped through...
-rw-r--r--newgrf.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/newgrf.c b/newgrf.c
index 8ed010793..295ab8b2d 100644
--- a/newgrf.c
+++ b/newgrf.c
@@ -1783,7 +1783,7 @@ static void VehicleNewName(byte *buf, int len)
switch (GB(id, 8, 8)) {
case 0xC4: /* Station class name */
if (GB(id, 0, 8) >= _cur_grffile->num_stations) {
- grfmsg(GMS_WARN, "VehicleNewName: Attempt to name undefined station 0x%X, ignoring.", station);
+ grfmsg(GMS_WARN, "VehicleNewName: Attempt to name undefined station 0x%X, ignoring.", GB(id, 0, 8));
} else {
StationClassID sclass = _cur_grffile->stations[GB(id, 0, 8)].sclass;
SetStationClassName(sclass, AddGRFString(_cur_grffile->grfid, id, lang, new_scheme, name));
@@ -1792,9 +1792,9 @@ static void VehicleNewName(byte *buf, int len)
case 0xC5: /* Station name */
if (GB(id, 0, 8) >= _cur_grffile->num_stations) {
- grfmsg(GMS_WARN, "VehicleNewName: Attempt to name undefined station 0x%X, ignoring.", station);
+ grfmsg(GMS_WARN, "VehicleNewName: Attempt to name undefined station 0x%X, ignoring.", GB(id, 0, 8));
} else {
- _cur_grffile->stations[station].name = AddGRFString(_cur_grffile->grfid, id, lang, new_scheme, name);
+ _cur_grffile->stations[GB(id, 0, 8)].name = AddGRFString(_cur_grffile->grfid, id, lang, new_scheme, name);
}
break;