Add last load factors

This commit is contained in:
KennyTV 2020-06-09 08:38:22 +02:00
parent 5d8084986f
commit f408a5d4c6
No known key found for this signature in database
GPG Key ID: 6BE3B555EBC5982B
5 changed files with 6 additions and 6 deletions

View File

@ -137,7 +137,7 @@ public class ProtocolRegistry {
protocols.put(protocol.getClass(), protocol);
for (int version : supported) {
Int2ObjectMap<Protocol> protocolMap = registryMap.computeIfAbsent(version, s -> new Int2ObjectOpenHashMap<>(1));
Int2ObjectMap<Protocol> protocolMap = registryMap.computeIfAbsent(version, s -> new Int2ObjectOpenHashMap<>(2));
protocolMap.put(output, protocol);
}

View File

@ -10,7 +10,7 @@ import java.util.Map;
import java.util.concurrent.ConcurrentHashMap;
public class BlockStorage extends StoredObject {
private static final IntSet WHITELIST = new IntOpenHashSet(46);
private static final IntSet WHITELIST = new IntOpenHashSet(46, 1F);
private final Map<Position, ReplacementData> blocks = new ConcurrentHashMap<>();
static {

View File

@ -40,7 +40,7 @@ public class MappingData {
JsonObject heightMapData = MappingDataLoader.loadData("heightMapData-1.14.json");
JsonArray motionBlocking = heightMapData.getAsJsonArray("MOTION_BLOCKING");
MappingData.motionBlocking = new IntOpenHashSet(motionBlocking.size());
MappingData.motionBlocking = new IntOpenHashSet(motionBlocking.size(), 1F);
for (JsonElement blockState : motionBlocking) {
String key = blockState.getAsString();
Integer id = blockStateMap.get(key);
@ -52,7 +52,7 @@ public class MappingData {
}
if (Via.getConfig().isNonFullBlockLightFix()) {
nonFullBlocks = new IntOpenHashSet(1611);
nonFullBlocks = new IntOpenHashSet(1611, 1F);
for (Map.Entry<String, JsonElement> blockstates : mapping1_13_2.getAsJsonObject("blockstates").entrySet()) {
final String state = blockstates.getValue().getAsString();
if (state.contains("_slab") || state.contains("_stairs") || state.contains("_wall["))

View File

@ -19,7 +19,7 @@ public class ItemRewriter {
private static final Map<String, Integer> POTION_NAME_TO_ID = new HashMap<>();
private static final Map<Integer, String> POTION_ID_TO_NAME = new HashMap<>();
private static final Int2IntMap POTION_INDEX = new Int2IntOpenHashMap(36);
private static final Int2IntMap POTION_INDEX = new Int2IntOpenHashMap(36, 1F);
static {
/* Entities */

View File

@ -5,7 +5,7 @@ import it.unimi.dsi.fastutil.ints.Int2IntOpenHashMap;
public class Effect {
private static final Int2IntMap EFFECTS = new Int2IntOpenHashMap(17);
private static final Int2IntMap EFFECTS = new Int2IntOpenHashMap(17, 1F);
static {
addRewrite(1005, 1010); //Play music disc