aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornathansmithsmith <nathansmith7@mailfence.com>2023-11-06 15:22:04 -0700
committernathansmithsmith <nathansmith7@mailfence.com>2023-11-06 15:22:04 -0700
commit4ca42bd3b6a55ee92cdf1af0f3137ab815f0375d (patch)
treee1c0a0070dc4f81f082d168aeb457eb71520aed7
parent68c003f0b7b491a3b30e4e86f2036bcf3d92f9c0 (diff)
Started kill log
-rw-r--r--src/killLog.c12
-rw-r--r--src/killLog.h24
2 files changed, 36 insertions, 0 deletions
diff --git a/src/killLog.c b/src/killLog.c
new file mode 100644
index 0000000..81ad7c1
--- /dev/null
+++ b/src/killLog.c
@@ -0,0 +1,12 @@
+#include "killLog.h"
+#include "game.h"
+
+void initKillLog(KillLog * killLog) {
+ killLog->killCount = 0;
+}
+
+void pushKill(KillLog * killLog, Kill kill) {
+}
+
+void drawKillLog(KillLog * killLog) {
+}
diff --git a/src/killLog.h b/src/killLog.h
new file mode 100644
index 0000000..22f2962
--- /dev/null
+++ b/src/killLog.h
@@ -0,0 +1,24 @@
+#include "gameCommon.h"
+#include "entity.h"
+
+#ifndef KILL_LOG_H
+#define KILL_LOG_H
+
+#define KILL_LOG_MAX 5
+
+typedef struct Kill {
+ EntityId id;
+ EntityFingerprint fingerPrint;
+ double timeAtKill;
+} Kill;
+
+typedef struct KillLog {
+ Kill kills[KILL_LOG_MAX];
+ size_t killCount;
+} KillLog;
+
+void initKillLog(KillLog * killLog);
+void pushKill(KillLog * killLog, Kill kill);
+void drawKillLog(KillLog * killLog);
+
+#endif