From: PilzAdam Date: Sat, 12 Jan 2013 19:49:55 +0000 (+0100) Subject: Fix spread of items in falling code X-Git-Url: http://81.2.79.47:8989/gitweb/?a=commitdiff_plain;h=443bbe6a785721bcaedf02f26c8a32d98ba63aec;p=zefram%2Fminetest%2Fminetest_engine.git Fix spread of items in falling code --- diff --git a/builtin/falling.lua b/builtin/falling.lua index 903c5dfd..d3af36f2 100644 --- a/builtin/falling.lua +++ b/builtin/falling.lua @@ -96,9 +96,9 @@ function drop_attached_node(p) minetest.env:remove_node(p) for _,item in ipairs(minetest.get_node_drops(nn, "")) do local pos = { - x = p.x + math.random(60)/60-0.3, - y = p.y + math.random(60)/60-0.3, - z = p.z + math.random(60)/60-0.3, + x = p.x + math.random()/2 - 0.25, + y = p.y + math.random()/2 - 0.25, + z = p.z + math.random()/2 - 0.25, } minetest.env:add_item(pos, item) end