mirror of
https://github.com/mt-mods/mail.git
synced 2025-03-20 16:41:25 +00:00
Permit start composition of a message by passing receivers into /mail command (close #101)
This commit is contained in:
parent
d53b07451c
commit
8dadd8043c
1 changed files with 6 additions and 2 deletions
|
@ -1,6 +1,10 @@
|
||||||
minetest.register_chatcommand("mail",{
|
minetest.register_chatcommand("mail",{
|
||||||
description = "Open the mail interface",
|
description = "Open the mail interface",
|
||||||
func = function(name)
|
func = function(name, param)
|
||||||
mail.show_mail_menu(name)
|
if #param > 0 then -- if param is not empty
|
||||||
|
mail.show_compose(name, param) -- make a new message
|
||||||
|
else
|
||||||
|
mail.show_mail_menu(name) -- show main menu
|
||||||
|
end
|
||||||
end
|
end
|
||||||
})
|
})
|
||||||
|
|
Loading…
Add table
Reference in a new issue