mirror of
https://codeberg.org/usrib/emeraldbank.git
synced 2024-12-23 06:32:25 +01:00
/money command
This commit is contained in:
parent
a4fa4c21ef
commit
94014e9173
13
commands.lua
13
commands.lua
@ -41,6 +41,19 @@ core.register_chatcommand("pay", {
|
|||||||
end
|
end
|
||||||
})
|
})
|
||||||
|
|
||||||
|
-- user /money chat command
|
||||||
|
core.register_chatcommand("money", {
|
||||||
|
description = S("Return your emeralds in your bank account."),
|
||||||
|
func = function(name, param)
|
||||||
|
local emeralds = emeraldbank.get_emeralds(name)
|
||||||
|
if emeralds then
|
||||||
|
minetest.chat_send_player(name, S("Emeralds in Bank: @1", emeralds))
|
||||||
|
return true
|
||||||
|
end
|
||||||
|
return false
|
||||||
|
end
|
||||||
|
})
|
||||||
|
|
||||||
-- admin chat command
|
-- admin chat command
|
||||||
core.register_chatcommand("emeralds", {
|
core.register_chatcommand("emeralds", {
|
||||||
params = "<player> <num>",
|
params = "<player> <num>",
|
||||||
|
Loading…
Reference in New Issue
Block a user