Package net.frozenblock.lib.networking
Class FrozenNetworking
java.lang.Object
net.frozenblock.lib.networking.FrozenNetworking
-
Method Summary
Modifier and TypeMethodDescriptionstatic booleanstatic booleanstatic booleanisLocalPlayer(net.minecraft.world.entity.player.Player player) static booleanstatic voidstatic voidsendPacketToAllPlayers(@NotNull net.minecraft.server.level.ServerLevel world, net.minecraft.network.protocol.common.custom.CustomPacketPayload payload)
-
Method Details
-
registerNetworking
public static void registerNetworking() -
sendPacketToAllPlayers
public static void sendPacketToAllPlayers(@NotNull @NotNull net.minecraft.server.level.ServerLevel world, net.minecraft.network.protocol.common.custom.CustomPacketPayload payload) -
isLocalPlayer
public static boolean isLocalPlayer(net.minecraft.world.entity.player.Player player) -
connectedToIntegratedServer
public static boolean connectedToIntegratedServer() -
connectedToServer
public static boolean connectedToServer()- Returns:
- if the client is connected to any server
-
isMultiplayer
public static boolean isMultiplayer()- Returns:
- if the current server is multiplayer (LAN/dedicated) or not (singleplayer)
-