Skip to main content

Listeners

Editable bridge hooks for Wasabi Chat (wasabi_chat). These are not exports.

Files

  • Client: bridge/notify/client.lua

Keep listener implementations non-blocking.


Client listeners​

ListenerParametersCalled when
wristLinkkind, title, messageA Wrist Link notification is about to show.
wristLinkItemmessageWrist Link could not open in item mode (no watch in the inventory, or the watch could not be read).

kind is one of 'direct_message', 'direct_reply', 'incoming_request', 'request_accepted', or 'custom'. Notifications sent with the sendWristNotification export use 'custom'.

Replacing hooks​

Return true from wristLink to replace the built-in watch notification with your own. Return false to keep the built-in one (default).

Wrist Link still decides who gets notified and handles mute, privacy, and sound, so do not play sounds here.

Example​

function notify.wristLink(kind, title, message)
exports.wasabi_notify:notify(title, message, 3500, 'info', false)
return true
end

function notify.wristLinkItem(message)
exports.wasabi_notify:notify('Wrist Link', message, 3500, 'error', false)
end