KattonEvents

Provides Kotlin-friendly wrappers around various Fabric API events.

Each nested object groups related server-side events and exposes them as reloadable Event properties via top.katton.util.Event.createReloadable.

The wrappers adapt Fabric's Java-style callback invokers into concise Kotlin lambdas, making event handling ergonomical for Kotlin-based mods.

Central container object that organizes event wrappers into logical groups.

Use KattonEvents.. to access the corresponding reloadable event bridge for registering handlers.

Types

Link copied to clipboard
object Block

Block interaction events (use with or without item).

Link copied to clipboard

Default item component modification events.

Link copied to clipboard

Enchantment related events (allow enchanting with TriState semantics, modify).

Link copied to clipboard

Elytra related entity events.

Link copied to clipboard

Entity sleeping related events (allow/start/stop/bed/nearby monsters etc.).

Link copied to clipboard
object Item

Item interaction events (use / useOn).

Link copied to clipboard
object LootTable

Loot table related events (replace/modify/all loaded/modify drops).

Link copied to clipboard
object Player

Player interaction events (attack/use interactions).

Link copied to clipboard

Player block break lifecycle events (before/after/canceled).

Link copied to clipboard

Player pick-item events (from block / from entity).

Link copied to clipboard

Server block-entity lifecycle events (load/unload).

Link copied to clipboard

Server chunk lifecycle events (load/generate/unload/level-type change).

Link copied to clipboard

General server entity lifecycle events (load/unload/equipment changes).

Link copied to clipboard

Server entity combat events (after killed other entity).

Link copied to clipboard

Server entity world change events (after entity/player change world).

Link copied to clipboard

Server lifecycle related events: server start/stop, datapack reload, save hooks.

Link copied to clipboard

Server-side living entity events (allow damage, after damage, allow death, after death, conversion).

Link copied to clipboard

Server-side message events (chat/game/command allow and handlers).

Link copied to clipboard

Mob effect events on the server (allow add / before/after add / allow early remove / before/after remove).

Link copied to clipboard

ServerPlayer specific events (join/leave/respawn/copy/allow death legacy).

Link copied to clipboard
object ServerTick

Server tick events (server/world start/end ticks).