From 6b82f1dc06f8f197cd54ea87b167eaf60f276846 Mon Sep 17 00:00:00 2001 From: peter1138 Date: Tue, 2 Jan 2007 20:00:10 +0000 Subject: (svn r7760) -Codechange: Debug messages for newgrf showed the starting sprite, not the current sprite index. Also only output the debug message during activation, when sprites are loaded. --- src/newgrf.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/newgrf.c b/src/newgrf.c index c2b4e464b..c1ecd359e 100644 --- a/src/newgrf.c +++ b/src/newgrf.c @@ -3682,8 +3682,10 @@ void LoadNewGRF(uint load_index, uint file_index) if (stage == GLS_LABELSCAN) InitNewGRFFile(c, _cur_spriteid); LoadNewGRFFile(c, slot++, stage); - if (stage == GLS_ACTIVATION) ClearTemporaryNewGRFData(); - DEBUG(sprite, 2, "Currently %i sprites are loaded", load_index); + if (stage == GLS_ACTIVATION) { + ClearTemporaryNewGRFData(); + DEBUG(sprite, 2, "Currently %i sprites are loaded", _cur_spriteid); + } } } -- cgit v1.2.3-70-g09d2