From 13a02e43417db9c49caea487e794a31e96f19069 Mon Sep 17 00:00:00 2001 From: alek13 Date: Tue, 3 Oct 2023 22:24:04 +0300 Subject: [PATCH] Mobs: Traders: Return forgotten money to player or drop int world. Closes lord-server/lord#1156 --- minetest_types.lua | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/minetest_types.lua b/minetest_types.lua index c8b8edf..09b3733 100644 --- a/minetest_types.lua +++ b/minetest_types.lua @@ -992,6 +992,8 @@ function minetest.add_item(pos, item) end --- Get an `ObjectRef` to a player --- --- [View in lua_api.txt](https://github.com/minetest/minetest/blob/5.4.1/doc/lua_api.txt#L4913-L4913) +--- @param name string +--- @return Player function minetest.get_player_by_name(name) end --- Returns a list of --- ObjectRefs. @@ -1634,6 +1636,10 @@ function minetest.item_place(itemstack, placer, pointed_thing, param2) end --- * returns the leftover itemstack --- --- [View in lua_api.txt](https://github.com/minetest/minetest/blob/5.4.1/doc/lua_api.txt#L5376-L5378) +--- @param itemstack ItemStack +--- @param dropper Player|ObjectRef +--- @param pos Position +--- @return ItemStack function minetest.item_drop(itemstack, dropper, pos) end --- * Returns `function(itemstack, user, pointed_thing)` as a --- function wrapper for `minetest.do_item_eat`.