More conditional orders: Extended save/load changes.

This commit is contained in:
Jonathan G Rennison
2015-08-26 23:15:33 +01:00
parent 0372bfcda7
commit 77bcd5f2c2
4 changed files with 3 additions and 3 deletions

View File

@@ -45,6 +45,7 @@ std::vector<uint32> _sl_xv_discardable_chunk_ids; ///< list of chunks
static const uint32 _sl_xv_slxi_chunk_version = 0; ///< current version os SLXI chunk static const uint32 _sl_xv_slxi_chunk_version = 0; ///< current version os SLXI chunk
const SlxiSubChunkInfo _sl_xv_sub_chunk_infos[] = { const SlxiSubChunkInfo _sl_xv_sub_chunk_infos[] = {
{ XSLFI_MORE_COND_ORDERS, XSCF_NULL, 1, 1, "more_cond_orders", NULL, NULL, NULL },
{ XSLFI_NULL, XSCF_NULL, 0, 0, NULL, NULL, NULL, NULL },// This is the end marker { XSLFI_NULL, XSCF_NULL, 0, 0, NULL, NULL, NULL, NULL },// This is the end marker
}; };

View File

@@ -21,6 +21,7 @@
*/ */
enum SlXvFeatureIndex { enum SlXvFeatureIndex {
XSLFI_NULL = 0, ///< Unused value, to indicate that no extended feature test is in use XSLFI_NULL = 0, ///< Unused value, to indicate that no extended feature test is in use
XSLFI_MORE_COND_ORDERS, ///< More conditional orders patch
XSLFI_SIZE, ///< Total count of features, including null feature XSLFI_SIZE, ///< Total count of features, including null feature
}; };

View File

@@ -113,7 +113,7 @@ const SaveLoad *GetOrderDescription()
SLE_CONDVAR(Order, wait_time, SLE_UINT16, 67, SL_MAX_VERSION), SLE_CONDVAR(Order, wait_time, SLE_UINT16, 67, SL_MAX_VERSION),
SLE_CONDVAR(Order, travel_time, SLE_UINT16, 67, SL_MAX_VERSION), SLE_CONDVAR(Order, travel_time, SLE_UINT16, 67, SL_MAX_VERSION),
SLE_CONDVAR(Order, max_speed, SLE_UINT16, 172, SL_MAX_VERSION), SLE_CONDVAR(Order, max_speed, SLE_UINT16, 172, SL_MAX_VERSION),
SLE_CONDVAR(Order, jump_counter, SLE_INT8, SL_CONDORDERS, SL_MAX_VERSION), SLE_CONDVAR_X(Order, jump_counter, SLE_INT8, 0, SL_MAX_VERSION, SlXvFeatureTest(XSLFTO_AND, XSLFI_MORE_COND_ORDERS)),
/* Leftover from the minor savegame version stuff /* Leftover from the minor savegame version stuff
* We will never use those free bytes, but we have to keep this line to allow loading of old savegames */ * We will never use those free bytes, but we have to keep this line to allow loading of old savegames */

View File

@@ -93,8 +93,6 @@ enum SLRefType {
/** Highest possible savegame version. */ /** Highest possible savegame version. */
#define SL_MAX_VERSION UINT16_MAX #define SL_MAX_VERSION UINT16_MAX
#define SL_CONDORDERS 200
/** Flags of a chunk. */ /** Flags of a chunk. */
enum ChunkType { enum ChunkType {
CH_RIFF = 0, CH_RIFF = 0,