summaryrefslogtreecommitdiff
path: root/include/wall_item.h
diff options
context:
space:
mode:
authorAldrik Ramaekers <aldrik@amftech.nl>2022-12-16 23:21:47 +0100
committerAldrik Ramaekers <aldrik@amftech.nl>2022-12-16 23:21:47 +0100
commit89984db7afa433e2842c4ef8c8c265a3e3993636 (patch)
tree127a939c0d02ba66600c353319be94cdf3906fc0 /include/wall_item.h
parent24a44e57ab9adbb353adac8b83c4441e7adb3751 (diff)
work
Diffstat (limited to 'include/wall_item.h')
-rw-r--r--include/wall_item.h33
1 files changed, 33 insertions, 0 deletions
diff --git a/include/wall_item.h b/include/wall_item.h
new file mode 100644
index 0000000..2e6bdd3
--- /dev/null
+++ b/include/wall_item.h
@@ -0,0 +1,33 @@
+#ifndef INCLUDE_WALL_ITEM
+#define INCLUDE_WALL_ITEM
+
+#include <projectbase/project_base.h>
+
+#include "guns.h"
+
+typedef enum t_wall_item_type {
+ WALLITEM_GUN,
+} wall_item_type;
+
+typedef union t_wall_item_data {
+ gun_type gun;
+} wall_item_data;
+
+typedef struct t_wall_item {
+ bool active;
+ vec3f position;
+ float time_active;
+ float start_h;
+ wall_item_type item;
+ wall_item_data data;
+ image* img;
+} wall_item;
+
+#define MAX_WALLITEMS (20)
+wall_item wallitems[MAX_WALLITEMS] = {0};
+
+void update_wallitems();
+void draw_wallitems(platform_window* window);
+void create_wallitem(vec3f position, wall_item_type item, wall_item_data data);
+
+#endif \ No newline at end of file