diff options
author | peter1138 <peter1138@openttd.org> | 2006-12-14 15:14:29 +0000 |
---|---|---|
committer | peter1138 <peter1138@openttd.org> | 2006-12-14 15:14:29 +0000 |
commit | 5772da18b2b6b43fcfa3e970a8c68fd8653509d0 (patch) | |
tree | 6752480ea013d248ce45a8571ddba265f3df08fd /newgrf.c | |
parent | dd42d07d2a268e836bfcbc70f73764c454637822 (diff) | |
download | openttd-5772da18b2b6b43fcfa3e970a8c68fd8653509d0.tar.xz |
(svn r7495) -Fix (r7354): [NewGRF] Deactivate the target GRF, not the current GRF.
Diffstat (limited to 'newgrf.c')
-rw-r--r-- | newgrf.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -2950,13 +2950,13 @@ static void GRFInhibit(byte *buf, int len) for (i = 0; i < num; i++) { uint32 grfid = grf_load_dword(&buf); - GRFFile *file = GetFileByGRFID(grfid); + GRFConfig *file = GetGRFConfig(grfid); /* Unset activation flag */ if (file != NULL) { grfmsg(GMS_NOTICE, "GRFInhibit: Deactivating file ``%s''", file->filename); - SETBIT(_cur_grfconfig->flags, GCF_DISABLED); - CLRBIT(_cur_grfconfig->flags, GCF_ACTIVATED); + SETBIT(file->flags, GCF_DISABLED); + CLRBIT(file->flags, GCF_ACTIVATED); } } } |