Move player a bit deeper into the biome in adjust
parent
c62e71858e
commit
192582a997
6
init.lua
6
init.lua
|
@ -63,10 +63,16 @@ local function adjust_pos_to_biome_limits(pos, biome_id)
|
||||||
if bpos[ax] < min then
|
if bpos[ax] < min then
|
||||||
out_of_bounds = true
|
out_of_bounds = true
|
||||||
bpos[ax] = min
|
bpos[ax] = min
|
||||||
|
if max-min > 16 then
|
||||||
|
bpos[ax] = math.max(bpos[ax] + 8, -playable_limit)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
if bpos[ax] > max then
|
if bpos[ax] > max then
|
||||||
out_of_bounds = true
|
out_of_bounds = true
|
||||||
bpos[ax] = max
|
bpos[ax] = max
|
||||||
|
if max-min > 16 then
|
||||||
|
bpos[ax] = math.min(bpos[ax] - 8, playable_limit)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
return bpos, out_of_bounds
|
return bpos, out_of_bounds
|
||||||
|
|
Loading…
Reference in New Issue