mirror of
https://github.com/mt-mods/mail.git
synced 2025-07-14 18:31:52 -04:00
Add API callback specifically for players receiving mail
This commit is contained in:
parent
3046f46414
commit
c7f631664e
3 changed files with 21 additions and 5 deletions
5
api.lua
5
api.lua
|
@ -10,6 +10,11 @@ function mail.register_on_receive(func)
|
|||
mail.registered_on_receives[#mail.registered_on_receives + 1] = func
|
||||
end
|
||||
|
||||
mail.registered_on_player_receives = {}
|
||||
function mail.register_on_player_receive(func)
|
||||
table.insert(mail.registered_on_player_receives, func)
|
||||
end
|
||||
|
||||
mail.registered_recipient_handlers = {}
|
||||
function mail.register_recipient_handler(func)
|
||||
table.insert(mail.registered_recipient_handlers, func)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue