src/newgrf_commons.cpp
changeset 7235 be9f15574c61
parent 7000 603a41cb93f8
child 7238 8986d0158eb9
equal deleted inserted replaced
7234:c6d0e14ae80b 7235:be9f15574c61
    71  */
    71  */
    72 uint16 OverrideManagerBase::GetID(uint8 grf_local_id, uint32 grfid)
    72 uint16 OverrideManagerBase::GetID(uint8 grf_local_id, uint32 grfid)
    73 {
    73 {
    74 	const EntityIDMapping *map;
    74 	const EntityIDMapping *map;
    75 
    75 
    76 	for (uint16 id = max_offset; id < max_new_entities; id++) {
    76 	for (uint16 id = 0; id < max_new_entities; id++) {
    77 		map = &mapping_ID[id];
    77 		map = &mapping_ID[id];
    78 		if (map->entity_id == grf_local_id && map->grfid == grfid) {
    78 		if (map->entity_id == grf_local_id && map->grfid == grfid) {
    79 			return id;
    79 			return id;
    80 		}
    80 		}
    81 	}
    81 	}