Class ClientPlayerNetworkEvent

java.lang.Object
net.minecraftforge.eventbus.api.Event
net.minecraftforge.client.event.ClientPlayerNetworkEvent
Direct Known Subclasses:
ClientPlayerNetworkEvent.Clone, ClientPlayerNetworkEvent.LoggingIn, ClientPlayerNetworkEvent.LoggingOut

public abstract class ClientPlayerNetworkEvent extends net.minecraftforge.eventbus.api.Event
Fired for different client connectivity events. See the various subclasses to listen for specific events.

These events are fired on the main Forge event bus, only on the logical client.

See Also:
  • Field Details

  • Constructor Details

  • Method Details

    • getMultiPlayerGameMode

      public MultiPlayerGameMode getMultiPlayerGameMode()
      Returns the multiplayer game mode controller for the player.
      Returns:
      the multiplayer game mode controller for the player
    • getPlayer

      public LocalPlayer getPlayer()
      Returns the player instance.
      Returns:
      the player instance
    • getConnection

      public Connection getConnection()
      Returns the network connection for the player.
      Returns:
      the network connection for the player