changeset 18051:870d93502d37 draft

(svn r22866) -Fix (r16396): Generic callbacks shall chain to the next GRF when the callback fails.
author frosch <frosch@openttd.org>
date Thu, 01 Sep 2011 19:40:51 +0000
parents 0a68432dcea1
children ef00ecdc853c
files src/newgrf_generic.cpp
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/newgrf_generic.cpp
+++ b/src/newgrf_generic.cpp
@@ -148,7 +148,7 @@
 		const SpriteGroup *group = it->group;
 		object->grffile = it->file;
 		group = SpriteGroup::Resolve(group, object);
-		if (group == NULL) continue;
+		if (group == NULL || group->GetCallbackResult() == CALLBACK_FAILED) continue;
 
 		/* Return NewGRF file if necessary */
 		if (file != NULL) *file = it->file;