mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-04 18:41:51 +00:00
advanced chunks loading test
This commit is contained in:
parent
b1fc666448
commit
09e641fd91
1 changed files with 10 additions and 5 deletions
|
|
@ -1,13 +1,18 @@
|
|||
test.set_setting("chunks.load-distance", 3)
|
||||
test.set_setting("chunks.load-speed", 16)
|
||||
test.set_setting("chunks.load-speed", 32)
|
||||
|
||||
test.reconfig_packs({"base"}, {})
|
||||
test.new_world("demo", "2019", "core:default")
|
||||
local pid = player.create("Xerxes")
|
||||
assert(player.get_name(pid) == "Xerxes")
|
||||
test.sleep_until(function() return block.get(0, 0, 0) >= 0 end, 1000)
|
||||
print(world.count_chunks())
|
||||
|
||||
block.destruct(0, 0, 0, pid)
|
||||
assert(block.get(0, 0, 0) == 0)
|
||||
for i=1,100 do
|
||||
if i % 10 == 0 then
|
||||
print(tostring(i).." % done")
|
||||
print("chunks loaded", world.count_chunks())
|
||||
end
|
||||
player.set_pos(pid, math.random() * 100 - 50, 100, math.random() * 100 - 50)
|
||||
test.tick()
|
||||
end
|
||||
|
||||
test.close_world(true)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue