summaryrefslogtreecommitdiff
path: root/src/group_cmd.cpp
diff options
context:
space:
mode:
authorsmatz <smatz@openttd.org>2009-01-04 15:32:25 +0000
committersmatz <smatz@openttd.org>2009-01-04 15:32:25 +0000
commit7368c740a646c958797b5dff90d6c5b51236e2a4 (patch)
tree56e0ff1f4048e467cf123e92ca788c3c4bbc0f94 /src/group_cmd.cpp
parentc9e8fd307e36b3d35f5bf7d01cffe64b1e75b846 (diff)
downloadopenttd-7368c740a646c958797b5dff90d6c5b51236e2a4.tar.xz
(svn r14828) -Codechange: move most of save/load-specific code to separate files
Diffstat (limited to 'src/group_cmd.cpp')
-rw-r--r--src/group_cmd.cpp38
1 files changed, 0 insertions, 38 deletions
diff --git a/src/group_cmd.cpp b/src/group_cmd.cpp
index 3a80c3d49..44e3b6bb3 100644
--- a/src/group_cmd.cpp
+++ b/src/group_cmd.cpp
@@ -6,7 +6,6 @@
#include "openttd.h"
#include "variables.h"
#include "command_func.h"
-#include "saveload.h"
#include "debug.h"
#include "group.h"
#include "train.h"
@@ -421,40 +420,3 @@ void RemoveAllGroupsForCompany(const CompanyID company)
if (company == g->owner) delete g;
}
}
-
-
-static const SaveLoad _group_desc[] = {
- SLE_CONDVAR(Group, name, SLE_NAME, 0, 83),
- SLE_CONDSTR(Group, name, SLE_STR, 0, 84, SL_MAX_VERSION),
- SLE_VAR(Group, num_vehicle, SLE_UINT16),
- SLE_VAR(Group, owner, SLE_UINT8),
- SLE_VAR(Group, vehicle_type, SLE_UINT8),
- SLE_VAR(Group, replace_protection, SLE_BOOL),
- SLE_END()
-};
-
-
-static void Save_GROUP(void)
-{
- Group *g;
-
- FOR_ALL_GROUPS(g) {
- SlSetArrayIndex(g->index);
- SlObject(g, _group_desc);
- }
-}
-
-
-static void Load_GROUP(void)
-{
- int index;
-
- while ((index = SlIterateArray()) != -1) {
- Group *g = new (index) Group();
- SlObject(g, _group_desc);
- }
-}
-
-extern const ChunkHandler _group_chunk_handlers[] = {
- { 'GRPS', Save_GROUP, Load_GROUP, CH_ARRAY | CH_LAST},
-};