# HG changeset patch # User yexo # Date 2010-12-10 22:18:16 # Node ID a27a75db3b7bfec4659f3409c00cee442b3e7787 # Parent 5c778f0982819857a01e41a876510719ab54db68 (svn r21456) -Fix: [NewGRF] make sure the parameter for house var 60 is the id of an original house diff --git a/src/newgrf_house.cpp b/src/newgrf_house.cpp --- a/src/newgrf_house.cpp +++ b/src/newgrf_house.cpp @@ -288,7 +288,7 @@ static uint32 HouseGetVariable(const Res case 0x47: return TileY(tile) << 16 | TileX(tile); /* Building counts for old houses with id = parameter. */ - case 0x60: return GetNumHouses(parameter, town); + case 0x60: return parameter < NEW_HOUSE_OFFSET ? GetNumHouses(parameter, town) : 0; /* Building counts for new houses with id = parameter. */ case 0x61: {