aboutsummaryrefslogtreecommitdiff
path: root/src/main/kotlin/moe/nea/ledger/ChatReceived.kt
blob: f3c4c50b89f0d32163d84a627b5f40a047d8ef3c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
package moe.nea.ledger

import net.minecraftforge.client.event.ClientChatReceivedEvent
import net.minecraftforge.fml.common.eventhandler.Event
import java.time.Instant

data class ChatReceived(
    val message: String,
    val timestamp: Instant = Instant.now()
) : Event() {
    constructor(event: ClientChatReceivedEvent) : this(
        event.message.unformattedText.unformattedString()
    )
}