MsmpEventRegistry

Registry for MSMP events.

@Serializable
public data class PlayerJoinedEvent(val eventCtx: PlayerDto) : MsmpEvent

public data object ServerStartedEvent : MsmpEvent

@Serializable
public data class IPBanRemovedEvent(val eventCtx: String) : MsmpEvent

MsmpEventRegistry.configure {
"minecraft:notification/players/joined" register PlayerJoinedEvent.serializer()

"minecraft:notification/server/started" bind ServerStartedEvent

"minecraft:notification/ip_bans/removed".define { p ->
IPBanRemovedEvent(p?.jsonPrimitive?.content ?: "")
}
}

Functions

Link copied to clipboard