summaryrefslogtreecommitdiff
path: root/src/saveload
diff options
context:
space:
mode:
authorPatric Stout <truebrain@openttd.org>2021-06-15 13:31:51 +0200
committerPatric Stout <github@truebrain.nl>2021-07-02 22:21:58 +0200
commit1ed240590799d0a2b724b226a512906908057e79 (patch)
treea2bfe9f6faa4e83e025633b11a2ae49ade6d686e /src/saveload
parent3826703bc3807c8af7372b550760fcd8286b9a6c (diff)
downloadopenttd-1ed240590799d0a2b724b226a512906908057e79.tar.xz
Cleanup: remove SLE_NULL and friends
We no longer need them. If you want to remove a field .. just remove it! Because of the headers in the savegame, on loading, it will do the right thing and skip the field. Do remember to bump the savegame version, as otherwise older clients can still load the game, but will reset the field you have removed .. that might be unintentially.
Diffstat (limited to 'src/saveload')
-rw-r--r--src/saveload/saveload.h22
1 files changed, 0 insertions, 22 deletions
diff --git a/src/saveload/saveload.h b/src/saveload/saveload.h
index a238d8c1b..77588a9f8 100644
--- a/src/saveload/saveload.h
+++ b/src/saveload/saveload.h
@@ -780,20 +780,6 @@ struct SaveLoadCompat {
#define SLE_REFLIST(base, variable, type) SLE_CONDREFLIST(base, variable, type, SL_MIN_VERSION, SL_MAX_VERSION)
/**
- * Empty space in every savegame version.
- * @param length Length of the empty space.
- */
-#define SLE_NULL(length) SLE_CONDNULL(length, SL_MIN_VERSION, SL_MAX_VERSION)
-
-/**
- * Empty space in some savegame versions.
- * @param length Length of the empty space.
- * @param from First savegame version that has the empty space.
- * @param to Last savegame version that has the empty space.
- */
-#define SLE_CONDNULL(length, from, to) SaveLoad {"", SL_NULL, SLE_FILE_U8 | SLE_VAR_NULL, length, from, to, 0, nullptr, 0, nullptr}
-
-/**
* Only write byte during saving; never read it during loading.
* When using SLE_SAVEBYTE you will have to read this byte before the table
* this is in is read. This also means SLE_SAVEBYTE can only be used at the
@@ -979,14 +965,6 @@ struct SaveLoadCompat {
#define SLEG_STRUCTLIST(name, handler) SLEG_CONDSTRUCTLIST(name, handler, SL_MIN_VERSION, SL_MAX_VERSION)
/**
- * Empty global space in some savegame versions.
- * @param length Length of the empty space.
- * @param from First savegame version that has the empty space.
- * @param to Last savegame version that has the empty space.
- */
-#define SLEG_CONDNULL(length, from, to) SaveLoad {"", SL_NULL, SLE_FILE_U8 | SLE_VAR_NULL, length, from, to, 0, nullptr, 0, nullptr}
-
-/**
* Field name where the real SaveLoad can be located.
* @param name The name of the field.
*/