forked from Mirrorlandia_minetest/emeraldbank
default price, default count
This commit is contained in:
parent
e8189b3641
commit
36e7cc8a9e
2
shop.lua
2
shop.lua
@ -128,6 +128,8 @@ core.register_node("emeraldbank:shop", {
|
|||||||
local meta = core.get_meta(pos)
|
local meta = core.get_meta(pos)
|
||||||
meta:set_string("infotext", S("Exchange shop (owned by @1)", owner))
|
meta:set_string("infotext", S("Exchange shop (owned by @1)", owner))
|
||||||
meta:set_string("owner", owner)
|
meta:set_string("owner", owner)
|
||||||
|
meta:set_int("count", 10) -- default count
|
||||||
|
meta:set_int("price", 5) -- default price
|
||||||
core.get_node_timer(pos):start(shop_timer)
|
core.get_node_timer(pos):start(shop_timer)
|
||||||
local inv = meta:get_inventory()
|
local inv = meta:get_inventory()
|
||||||
inv:set_size("stock", stock_w*stock_h)
|
inv:set_size("stock", stock_w*stock_h)
|
||||||
|
Loading…
Reference in New Issue
Block a user