Package net.minecraftforge.common.util
Class FakePlayerFactory
java.lang.Object
net.minecraftforge.common.util.FakePlayerFactory
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static Map<com.mojang.authlib.GameProfile,FakePlayer> private static com.mojang.authlib.GameProfileprivate static WeakReference<FakePlayer> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic FakePlayerget(ServerLevel level, com.mojang.authlib.GameProfile username) Get a fake player with a given username, Mods should either hold weak references to the return value, or listen for a WorldEvent.Unload and kill all references to prevent worlds staying in memory.static FakePlayergetMinecraft(ServerLevel level) static voidunloadLevel(ServerLevel level)
-
Field Details
-
MINECRAFT
private static com.mojang.authlib.GameProfile MINECRAFT -
fakePlayers
-
MINECRAFT_PLAYER
-
-
Constructor Details
-
FakePlayerFactory
public FakePlayerFactory()
-
-
Method Details
-
getMinecraft
-
get
Get a fake player with a given username, Mods should either hold weak references to the return value, or listen for a WorldEvent.Unload and kill all references to prevent worlds staying in memory. -
unloadLevel
-