mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-03-06 14:27:16 +00:00
(svn r959) -Fix: fix previous typo for workaround of braindead MSVC6 (Tron)
-Fix: added debug code to autosave cause it is buggy in multiplayer (does not remember settings; takes them from _opt instead of _new_opt (or vice versa)).
This commit is contained in:
parent
78b651c2c9
commit
860a39af2a
@ -92,7 +92,7 @@ enum {
|
|||||||
};
|
};
|
||||||
|
|
||||||
#define SLE_VAR(t,i,c) 0 | (offsetof(t,i) & 0xF), offsetof(t,i) >> 4, c
|
#define SLE_VAR(t,i,c) 0 | (offsetof(t,i) & 0xF), offsetof(t,i) >> 4, c
|
||||||
#if MSC_VER == 1200 /* XXX workaround for MSVC6 */
|
#if _MSC_VER == 1200 /* XXX workaround for MSVC6 */
|
||||||
#define SLE_VAR2(t0,i0, t1, i1, c) 0 | ((offsetof(t0, i0) + offsetof(t1, i1)) & 0xF), (offsetof(t0, i0) + offsetof(t1, i1)) >> 4, c
|
#define SLE_VAR2(t0,i0, t1, i1, c) 0 | ((offsetof(t0, i0) + offsetof(t1, i1)) & 0xF), (offsetof(t0, i0) + offsetof(t1, i1)) >> 4, c
|
||||||
#endif
|
#endif
|
||||||
#define SLE_REF(t,i,c) 0x10 | (offsetof(t,i) & 0xF), offsetof(t,i) >> 4, c
|
#define SLE_REF(t,i,c) 0x10 | (offsetof(t,i) & 0xF), offsetof(t,i) >> 4, c
|
||||||
|
1
ttd.c
1
ttd.c
@ -1015,6 +1015,7 @@ static void DoAutosave()
|
|||||||
sprintf(buf, "%s%sautosave%d.sav", _path.autosave_dir, PATHSEP, n);
|
sprintf(buf, "%s%sautosave%d.sav", _path.autosave_dir, PATHSEP, n);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
DEBUG(misc, 2) ("Autosaving to %s", buf);
|
||||||
if (SaveOrLoad(buf, SL_SAVE) != SL_OK)
|
if (SaveOrLoad(buf, SL_SAVE) != SL_OK)
|
||||||
ShowErrorMessage(INVALID_STRING_ID, STR_AUTOSAVE_FAILED, 0, 0);
|
ShowErrorMessage(INVALID_STRING_ID, STR_AUTOSAVE_FAILED, 0, 0);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user