Infinite world, LuaJIT mod API, WorldEdit port, skins and music

- Infinite world: streamed chunk cache, multi-region storage (old chunks.dat
  still loads), per-chunk entity/tile entity persistence, client chunk
  streaming, protocol version 10, view-distance server property
- LuaJIT mod host (mods/, lua/prelude.lua) with events, commands, world and
  player API; WorldEdit command set ported to it (mods/worldedit)
- /skin command, SetSkinPacket and bundled skins
- OGG music player (data/music is ignored, tools/convert-music.ps1)
- package-windows.ps1 builds client and dedicated server for Windows

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
Kirill Sokolov 2026-10-20 21:08:09 +03:00
parent db9f6c9f32
commit 110cb2a896
68 changed files with 5064 additions and 844 deletions

View file

@ -537,9 +537,13 @@ LevelChunk* RandomLevelSource::create(int x, int z) {
return getChunk(x, z);
}
void RandomLevelSource::releaseChunk(int x, int z) {
chunkMap.erase(LevelConstants::chunkKey(x, z));
}
LevelChunk* RandomLevelSource::getChunk(int xOffs, int zOffs) {
//static int chunkx = 0;
int hashedPos = ChunkPos::hashCode(xOffs, zOffs);
const long long hashedPos = LevelConstants::chunkKey(xOffs, zOffs);
ChunkMap::iterator it = chunkMap.find(hashedPos);
if (it != chunkMap.end())