Skip to content

Events API ​

Forge events live in emaki.jiuwu.craft.forge.api.event. Both are synchronous Bukkit events fired on the forging player's owner thread, and both the GUI forge path and the public ForgeOperations.forgeAsync share the same event contract

EventTimingThreadCancellableMutable fieldCancellation / outcomeRuntime paths
ForgeStartEventAfter validation and the prepared forge complete, just before asynchronous execution and material commitPlayer owner threadYessuccessRate; finite values clamp to 0–100, non-finite values become 0Cancelling stops the attempt without scheduling execution and without consuming materials; the API returns CANCELLEDGUI confirmation and forgeAsync
ForgeCompletedEventAfter a forge result has been resolved, for both successful and resolvable failed attemptsPlayer owner threadNoNonePost notification, cannot be rolled backGUI completion and forgeAsync completion

ForgeStartEvent exposes the player, recipe id, and first-craft flag as read-only values. ForgeCompletedEvent exposes success, result item, quality, and multiplier as read-only values; on failure the result item and quality may be empty

When owner or generation validation fails before the start, no start event is fired. During completion, if the player's owner scheduling has already retired, the result is still mapped and settled but the completed event can be skipped. A cancelled start produces no completed event. Catalog validation, opening the GUI or recipe book, and refreshing items are not themselves forge attempts