summaryrefslogtreecommitdiff
path: root/settings.h
diff options
context:
space:
mode:
authortruelight <truelight@openttd.org>2004-12-04 17:54:56 +0000
committertruelight <truelight@openttd.org>2004-12-04 17:54:56 +0000
commitb8f6d41418982163965dd5beb0b39dbdce1fbe8f (patch)
tree68d3e795694a875138c369707ed74b5b4b022d49 /settings.h
parent0434287ef826a4ed72cd8528a52a86ae8b70a948 (diff)
downloadopenttd-b8f6d41418982163965dd5beb0b39dbdce1fbe8f.tar.xz
(svn r942) -Merged branch/network back into the trunk
Diffstat (limited to 'settings.h')
-rw-r--r--settings.h39
1 files changed, 39 insertions, 0 deletions
diff --git a/settings.h b/settings.h
new file mode 100644
index 000000000..6e55862ed
--- /dev/null
+++ b/settings.h
@@ -0,0 +1,39 @@
+#ifndef SETTINGS_H
+#define SETTINGS_H
+
+enum SettingDescType {
+ SDT_INTX, // must be 0
+ SDT_ONEOFMANY,
+ SDT_MANYOFMANY,
+ SDT_BOOLX,
+ SDT_STRING,
+ SDT_STRINGBUF,
+ SDT_INTLIST,
+
+ SDT_INT8 = 0 << 4,
+ SDT_UINT8 = 1 << 4,
+ SDT_INT16 = 2 << 4,
+ SDT_UINT16 = 3 << 4,
+ SDT_INT32 = 4 << 4,
+ SDT_UINT32 = 5 << 4,
+ SDT_CALLBX = 6 << 4,
+
+ SDT_UINT = SDT_UINT32,
+ SDT_INT = SDT_INT32,
+
+ SDT_NOSAVE = 1 << 8,
+
+ SDT_CALLB = SDT_INTX | SDT_CALLBX,
+
+ SDT_BOOL = SDT_BOOLX | SDT_UINT8,
+};
+
+typedef struct SettingDesc {
+ const char *name;
+ int flags;
+ const void *def;
+ void *ptr;
+ const void *b;
+} SettingDesc;
+
+#endif /* SETTINGS_H */