Skip to content

Commit

Permalink
Replace use of place_node with add_node
Browse files Browse the repository at this point in the history
  • Loading branch information
Poikilos authored and raymoo committed Jun 7, 2019
1 parent e7398c3 commit b2fd945
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion dungeon.lua
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ minetest.register_on_generated(function(minp, maxp, blockseed)

for i, location in ipairs(locations) do
if math.random(3) == 1 then
minetest.place_node(location, { name = "loot:loot_node" })
minetest.add_node(location, { name = "loot:loot_node" })
end
end
end)
2 changes: 1 addition & 1 deletion loot_node.lua
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ minetest.register_abm({
chance = 1,
action = function(pos)
minetest.remove_node(pos)
minetest.place_node(pos, {name = "default:chest"})
minetest.add_node(pos, {name = "default:chest"})
local inv = minetest.get_meta(pos):get_inventory()

local valuable_count = math.random(1,3)
Expand Down

0 comments on commit b2fd945

Please sign in to comment.