mirror of
https://github.com/ViaVersion/ViaVersion.git
synced 2024-10-31 23:59:33 +01:00
Use weakhashmap
This commit is contained in:
parent
5cc421cff9
commit
10d8ce86b3
@ -45,7 +45,7 @@ public class PlayerSneakListener extends ViaBukkitListener {
|
|||||||
|
|
||||||
// From 1.9 upwards the server hitbox is set in every entity tick, so we have to reset it everytime
|
// From 1.9 upwards the server hitbox is set in every entity tick, so we have to reset it everytime
|
||||||
if (ProtocolRegistry.SERVER_PROTOCOL >= ProtocolVersion.v1_9.getId()) {
|
if (ProtocolRegistry.SERVER_PROTOCOL >= ProtocolVersion.v1_9.getId()) {
|
||||||
sneaking = new HashMap<>();
|
sneaking = new WeakHashMap<>();
|
||||||
useCache = true;
|
useCache = true;
|
||||||
plugin.getServer().getScheduler().runTaskTimer(plugin, new Runnable() {
|
plugin.getServer().getScheduler().runTaskTimer(plugin, new Runnable() {
|
||||||
@Override
|
@Override
|
||||||
|
Loading…
Reference in New Issue
Block a user