From a1acf425cfb00a41c7862c915eb024207658c814 Mon Sep 17 00:00:00 2001 From: Franklin Wei Date: Mon, 25 Jan 2016 16:10:46 -0500 Subject: inventory works --- src/util.h | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'src/util.h') diff --git a/src/util.h b/src/util.h index 0f05a89..fefd735 100644 --- a/src/util.h +++ b/src/util.h @@ -19,9 +19,20 @@ /* You should use #pragma once everywhere. */ #pragma once +#include "room.h" + /* utility functions */ void __attribute__((noreturn,format(printf,1,2))) error(const char *fmt, ...); void __attribute__((format(printf,4,5))) debugf_real(const char*, int, const char*, const char *fmt, ...); void remove_cruft(char*); void all_upper(char*); void all_lower(char*); + +void write_string(int fd, const char *str); +char *read_string(int fd); + +void write_roomid(int fd, room_id *id); +room_id read_roomid(int fd); + +void write_bool(int fd, bool b); +bool read_bool(int fd); -- cgit v1.1