aboutsummaryrefslogtreecommitdiff
path: root/src/main/kotlin/moe/nea/ledger/events
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/kotlin/moe/nea/ledger/events')
-rw-r--r--src/main/kotlin/moe/nea/ledger/events/ChatReceived.kt2
-rw-r--r--src/main/kotlin/moe/nea/ledger/events/InitializationComplete.kt6
-rw-r--r--src/main/kotlin/moe/nea/ledger/events/SupplyDebugInfo.kt10
3 files changed, 17 insertions, 1 deletions
diff --git a/src/main/kotlin/moe/nea/ledger/events/ChatReceived.kt b/src/main/kotlin/moe/nea/ledger/events/ChatReceived.kt
index e88c7a0..a352c27 100644
--- a/src/main/kotlin/moe/nea/ledger/events/ChatReceived.kt
+++ b/src/main/kotlin/moe/nea/ledger/events/ChatReceived.kt
@@ -10,6 +10,6 @@ data class ChatReceived(
val timestamp: Instant = Instant.now()
) : Event() {
constructor(event: ClientChatReceivedEvent) : this(
- event.message.unformattedText.unformattedString()
+ event.message.unformattedText.unformattedString().trimEnd()
)
} \ No newline at end of file
diff --git a/src/main/kotlin/moe/nea/ledger/events/InitializationComplete.kt b/src/main/kotlin/moe/nea/ledger/events/InitializationComplete.kt
new file mode 100644
index 0000000..d917039
--- /dev/null
+++ b/src/main/kotlin/moe/nea/ledger/events/InitializationComplete.kt
@@ -0,0 +1,6 @@
+package moe.nea.ledger.events
+
+import net.minecraftforge.fml.common.eventhandler.Event
+
+class InitializationComplete : Event() {
+} \ No newline at end of file
diff --git a/src/main/kotlin/moe/nea/ledger/events/SupplyDebugInfo.kt b/src/main/kotlin/moe/nea/ledger/events/SupplyDebugInfo.kt
new file mode 100644
index 0000000..cab0a20
--- /dev/null
+++ b/src/main/kotlin/moe/nea/ledger/events/SupplyDebugInfo.kt
@@ -0,0 +1,10 @@
+package moe.nea.ledger.events
+
+import net.minecraftforge.fml.common.eventhandler.Event
+
+class SupplyDebugInfo : Event() { // TODO: collect this in the event recorder
+ val data = mutableListOf<Pair<String, Any>>()
+ fun record(key: String, value: Any) {
+ data.add(key to value)
+ }
+} \ No newline at end of file