mirror of
https://github.com/darksaid98/HuskHomes.git
synced 2026-12-02 22:17:17 +00:00
Private home list display, caching
This commit is contained in:
1 parent
83d5a921ee
commit
bafd3837dd
10 files changed
+237
-19
No files matched your search
@@ -3,7 +3,7 @@ package net.william278.huskhomes.cache;
|
||||
import net.william278.huskhomes.HuskHomes;
|
||||
import net.william278.huskhomes.config.Settings;
|
||||
import net.william278.huskhomes.data.Database;
|
||||
import net.william278.huskhomes.messenger.NetworkMessenger;
|
||||
import net.william278.huskhomes.list.PositionList;
|
||||
import net.william278.huskhomes.player.Player;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
@@ -12,7 +12,6 @@ import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.UUID;
|
||||
import java.util.concurrent.CompletableFuture;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
* A cache used to hold persistently used data
|
||||
@@ -39,6 +38,11 @@ public class Cache {
|
||||
*/
|
||||
public final List<String> players;
|
||||
|
||||
/**
|
||||
* Cached position lists for optimized list navigating
|
||||
*/
|
||||
public final HashMap<UUID, PositionList> positionLists;
|
||||
|
||||
/**
|
||||
* Create a new cache
|
||||
*/
|
||||
@@ -47,6 +51,7 @@ public class Cache {
|
||||
this.publicHomes = new HashMap<>();
|
||||
this.warps = new ArrayList<>();
|
||||
this.players = new ArrayList<>();
|
||||
this.positionLists = new HashMap<>();
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in new issue
Block a user