Mirror von
https://github.com/ViaVersion/ViaVersion.git
synchronisiert 2024-12-27 08:30:09 +01:00
Replace keyset map lookups with value iterator
Dieser Commit ist enthalten in:
Ursprung
867cd4ee39
Commit
a82bbc4e66
@ -56,8 +56,8 @@ public class WorldPackets {
|
||||
}
|
||||
|
||||
CompoundTag heightMaps = chunk.getHeightMap();
|
||||
for (String key : heightMaps.keySet()) {
|
||||
LongArrayTag heightMap = heightMaps.get(key);
|
||||
for (Tag heightMapTag : heightMaps) {
|
||||
LongArrayTag heightMap = (LongArrayTag) heightMapTag;
|
||||
int[] heightMapData = new int[256];
|
||||
CompactArrayUtil.iterateCompactArray(9, heightMapData.length, heightMap.getValue(), (i, v) -> heightMapData[i] = v);
|
||||
heightMap.setValue(CompactArrayUtil.createCompactArrayWithPadding(9, heightMapData.length, i -> heightMapData[i]));
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren