(svn r10516) -Fix: if doing a lookup for a ID, scan the whole range instead of only the "new" ones because the old ones could be overriden too.
authorrubidium
Thu, 12 Jul 2007 07:53:53 +0000
changeset 7731 ae4ec8ea5ac5
parent 7730 a7b31d4fcc40
child 7732 f25c8aa26cc3
(svn r10516) -Fix: if doing a lookup for a ID, scan the whole range instead of only the "new" ones because the old ones could be overriden too.
src/newgrf_commons.cpp
--- a/src/newgrf_commons.cpp	Wed Jul 11 23:10:22 2007 +0000
+++ b/src/newgrf_commons.cpp	Thu Jul 12 07:53:53 2007 +0000
@@ -73,7 +73,7 @@
 {
 	const EntityIDMapping *map;
 
-	for (uint16 id = max_offset; id < max_new_entities; id++) {
+	for (uint16 id = 0; id < max_new_entities; id++) {
 		map = &mapping_ID[id];
 		if (map->entity_id == grf_local_id && map->grfid == grfid) {
 			return id;