M2.3: the shared world (trees, pickups, pieces, chests, fires, doors, graves, clock on the server)

This commit is contained in:
Paul Bailey
2026-11-04 18:12:49 +00:00
parent 74cbf96458
commit 0c18b6d49e
17 changed files with 1672 additions and 94 deletions

View File

@@ -252,10 +252,13 @@ func _result(path: String) -> Dictionary:
func _sleep(s: float) -> void:
await create_timer(s).timeout
## Deletes a folder and everything in it (a server's folder has its world in it).
func _rmdir(d: String) -> void:
var da := DirAccess.open(d)
if da == null:
return
for sub in da.get_directories():
_rmdir(d.path_join(sub))
for f in da.get_files():
da.remove(f)
DirAccess.remove_absolute(d)