aboutsummaryrefslogtreecommitdiff
path: root/src/client_reqs.h
diff options
context:
space:
mode:
authorFranklin Wei <git@fwei.tk>2016-02-16 21:17:46 -0500
committerFranklin Wei <git@fwei.tk>2016-02-16 21:17:46 -0500
commit02de31c48c021742c6245b711790f6d853866c36 (patch)
treed145f3ce9156de42064f8bceb3d0eb4362e3bb5a /src/client_reqs.h
parent8c58ee885941af4c944995b029363f139b8f54bd (diff)
downloadnetcosm-02de31c48c021742c6245b711790f6d853866c36.zip
netcosm-02de31c48c021742c6245b711790f6d853866c36.tar.gz
netcosm-02de31c48c021742c6245b711790f6d853866c36.tar.bz2
netcosm-02de31c48c021742c6245b711790f6d853866c36.tar.xz
refactor client_ module
Diffstat (limited to 'src/client_reqs.h')
-rw-r--r--src/client_reqs.h46
1 files changed, 46 insertions, 0 deletions
diff --git a/src/client_reqs.h b/src/client_reqs.h
new file mode 100644
index 0000000..979da9a
--- /dev/null
+++ b/src/client_reqs.h
@@ -0,0 +1,46 @@
+/*
+ * NetCosm - a MUD server
+ * Copyright (C) 2016 Franklin Wei
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#pragma once
+
+#include "globals.h"
+
+#include "server.h"
+#include "server_reqs.h"
+#include "userdb.h"
+
+enum reqdata_typespec { TYPE_NONE = 0, TYPE_USERDATA, TYPE_BOOLEAN } reqdata_type;
+
+union reqdata_t {
+ struct userdata_t userdata;
+ bool boolean;
+};
+
+extern enum reqdata_typespec reqdata_type;
+extern union reqdata_t returned_reqdata;
+
+void client_change_room(room_id id);
+void client_change_user(const char *user);
+void client_change_state(int state);
+bool client_move(const char *dir);
+void client_look(void);
+void client_look_at(char *obj);
+void client_inventory(void);
+void client_drop(char *what);
+void client_user_list(void);
+void client_take(char *obj);