forked from Kimapr/nodecore-skyblock
Random heights for islands, default max stack capacity to 100
This commit is contained in:
parent
0ec00d9ac7
commit
e2a0171d99
|
@ -42,6 +42,14 @@ setmetatable(nodecore, {
|
|||
end
|
||||
})
|
||||
|
||||
local rawregitem = minetest.register_item
|
||||
function minetest.register_item(name,item)
|
||||
if type(item) == "table" and item.stack_max == nil then
|
||||
item.stack_max = 100
|
||||
end
|
||||
rawregitem(name,item)
|
||||
end
|
||||
|
||||
include("issue7020")
|
||||
|
||||
include("util_misc")
|
||||
|
|
|
@ -99,7 +99,7 @@ local function gen_island_pos(name)
|
|||
end
|
||||
store:set_string(pid(x,z),name)
|
||||
local range = {min={x=x*128-64,y=256-64,z=z*128-64},max={x=x*128+64,y=256+64,z=z*128+64}}
|
||||
local ip = {x=x*128+math.random(-32,32),y=256,z=z*128+math.random(-32,32)}
|
||||
local ip = {x=x*128+math.random(-32,32),y=256+math.random(-32,32),z=z*128+math.random(-32,32)}
|
||||
spawn_island(name,ip)
|
||||
return pid(x,z),ip,range
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue