From b65ece1ea930a42763916d4dbfbaf1c190f3d2a9 Mon Sep 17 00:00:00 2001 From: frosch Date: Sun, 11 Nov 2012 12:57:27 +0000 Subject: (svn r24695) -Fix/Cleanup: Remove remaining (incorrect) usages of ResolverObject::scope and count. --- src/table/newgrf_debug_data.h | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'src/table/newgrf_debug_data.h') diff --git a/src/table/newgrf_debug_data.h b/src/table/newgrf_debug_data.h index 4446d7605..2f02b1404 100644 --- a/src/table/newgrf_debug_data.h +++ b/src/table/newgrf_debug_data.h @@ -75,7 +75,7 @@ class NIHVehicle : public NIHelper { { Vehicle *v = Vehicle::Get(index); VehicleResolverObject ro(v->engine_type, v); - return ro.GetScope(ro.scope)->GetVariable(var, param, avail); + return ro.GetScope(VSG_SCOPE_SELF)->GetVariable(var, param, avail); } }; @@ -137,7 +137,7 @@ class NIHStation : public NIHelper { /* virtual */ uint Resolve(uint index, uint var, uint param, bool *avail) const { StationResolverObject ro(GetStationSpec(index), Station::GetByTile(index), index); - return ro.GetScope(ro.scope)->GetVariable(var, param, avail); + return ro.GetScope(VSG_SCOPE_SELF)->GetVariable(var, param, avail); } }; @@ -202,7 +202,7 @@ class NIHHouse : public NIHelper { /* virtual */ uint Resolve(uint index, uint var, uint param, bool *avail) const { HouseResolverObject ro(GetHouseType(index), index, Town::GetByTile(index)); - return ro.GetScope(ro.scope)->GetVariable(var, param, avail); + return ro.GetScope(VSG_SCOPE_SELF)->GetVariable(var, param, avail); } }; @@ -252,7 +252,7 @@ class NIHIndustryTile : public NIHelper { /* virtual */ uint Resolve(uint index, uint var, uint param, bool *avail) const { IndustryTileResolverObject ro(GetIndustryGfx(index), index, Industry::GetByTile(index)); - return ro.GetScope(ro.scope)->GetVariable(var, param, avail); + return ro.GetScope(VSG_SCOPE_SELF)->GetVariable(var, param, avail); } }; @@ -325,7 +325,7 @@ class NIHIndustry : public NIHelper { { Industry *i = Industry::Get(index); IndustriesResolverObject ro(i->location.tile, i, i->type); - return ro.GetScope(ro.scope)->GetVariable(var, param, avail); + return ro.GetScope(VSG_SCOPE_SELF)->GetVariable(var, param, avail); } uint GetPSASize(uint index, uint32 grfid) const { return cpp_lengthof(PersistentStorage, storage); } @@ -389,7 +389,7 @@ class NIHObject : public NIHelper { /* virtual */ uint Resolve(uint index, uint var, uint param, bool *avail) const { ObjectResolverObject ro(ObjectSpec::GetByTile(index), Object::GetByTile(index), index); - return ro.GetScope(ro.scope)->GetVariable(var, param, avail); + return ro.GetScope(VSG_SCOPE_SELF)->GetVariable(var, param, avail); } }; @@ -423,7 +423,7 @@ class NIHRailType : public NIHelper { /* There is no unique GRFFile for the tile. Multiple GRFs can define different parts of the railtype. * However, currently the NewGRF Debug GUI does not display variables depending on the GRF (like 0x7F) anyway. */ RailTypeResolverObject ro(index, TCX_NORMAL, NULL); - return ro.GetScope(ro.scope)->GetVariable(var, param, avail); + return ro.GetScope(VSG_SCOPE_SELF)->GetVariable(var, param, avail); } }; @@ -457,7 +457,7 @@ class NIHAirportTile : public NIHelper { /* virtual */ uint Resolve(uint index, uint var, uint param, bool *avail) const { AirportTileResolverObject ro(AirportTileSpec::GetByTile(index), index, Station::GetByTile(index)); - return ro.GetScope(ro.scope)->GetVariable(var, param, avail); + return ro.GetScope(VSG_SCOPE_SELF)->GetVariable(var, param, avail); } }; @@ -497,7 +497,7 @@ class NIHTown : public NIHelper { /* virtual */ uint Resolve(uint index, uint var, uint param, bool *avail) const { TownResolverObject ro(NULL, Town::Get(index), true); - return ro.GetScope(ro.scope)->GetVariable(var, param, avail); + return ro.GetScope(VSG_SCOPE_SELF)->GetVariable(var, param, avail); } const int32 *GetPSAFirstPosition(uint index, uint32 grfid) const -- cgit v1.2.3-54-g00ecf