#include "map.h"
#include <stdint.h> /* uint8_t, int8_t, uint16_t, uint32_t, (U)INT*_(MIN|MAX) */
#include <stdlib.h> /* free() */
+#include <string.h> /* memset() */
#include "../common/rexit.h" /* exit_err() */
#include "../common/try_malloc.h" /* try_malloc() */
#include "../common/yx_uint8.h" /* yx_uint8 */
}
return 0;
}
+
+
+
+extern void init_empty_map(char ** map)
+{
+ *map = try_malloc(world.map.length * world.map.length, __func__);
+ memset(*map, ' ', world.map.length * world.map.length);
+}