枚举类 LogicalSide

java.lang.Object
java.lang.Enum<LogicalSide>
net.minecraftforge.fml.LogicalSide
所有已实现的接口:
Serializable, Comparable<LogicalSide>, Constable

public enum LogicalSide extends Enum<LogicalSide>
A logical side of the Minecraft game.

The client distribution has a copy of the logical client and the logical server, while the dedicated server distribution only holds the logical server.

另请参阅:
  • Dist
  • 枚举常量详细资料

    • CLIENT

      public static final LogicalSide CLIENT
      The logical client of the Minecraft game, which interfaces with the player's inputs and renders the player's viewpoint.

      The logical client is only shipped with the client distribution of the game.

      另请参阅:
      • Dist.CLIENT
    • SERVER

      public static final LogicalSide SERVER
      The logical server of the Minecraft game, responsible for connecting to clients and running the simulation logic on the level.

      The logical server is shipped with both client and dedicated server distributions. The client distribution runs the logical server for singleplayer mode and LAN play.

      另请参阅:
      • Dist.DEDICATED_SERVER
  • 构造器详细资料

    • LogicalSide

      private LogicalSide()
  • 方法详细资料

    • values

      public static LogicalSide[] values()
      返回包含该枚举类的常量的数组, 顺序与声明这些常量的顺序相同
      返回:
      包含该枚举类的常量的数组,顺序与声明这些常量的顺序相同
    • valueOf

      public static LogicalSide valueOf(String name)
      返回带有指定名称的该类的枚举常量。 字符串必须与用于声明该类的枚举常量的 标识符完全匹配。(不允许有多余 的空格字符。)
      参数:
      name - 要返回的枚举常量的名称。
      返回:
      返回带有指定名称的枚举常量
      抛出:
      IllegalArgumentException - 如果该枚举类没有带有指定名称的常量
      NullPointerException - 如果参数为空值
    • isServer

      public boolean isServer()
      返回 if this logical side is the server。
      返回:
      if this logical side is the server
    • isClient

      public boolean isClient()
      返回 if the logical side is the client。
      返回:
      if the logical side is the client