Class Options


  • public class Options
    extends java.lang.Object
    Command line argument parser.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static @NotNull java.lang.String DEFAULT_SKIN
      The default skin name.
    • Constructor Summary

      Constructors 
      Constructor Description
      Options()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      @Nullable java.lang.String getDebugKeyboardFilename()
      Returns the filename for keyboard debug logs.
      @Nullable java.lang.String getDebugMouseFilename()
      Returns the filename for mouse debug logs.
      @Nullable java.lang.String getDebugProtocolFilename()
      Returns the filename for Crossfire protocol debug logs.
      @Nullable java.lang.String getDebugScreenFilename()
      Returns the filename for screen debug logs.
      @Nullable java.lang.String getDebugSoundFilename()
      Returns the filename for sound debug logs.
      @Nullable Resolution getResolution()
      Returns the resolution.
      @Nullable java.lang.String getServer()
      Returns the Crossfire server to connect to.
      @NotNull java.lang.String getSkin()
      Returns the skin name.
      int getTileSize()
      Returns the size of a tile in the map view.
      boolean isAvoidCopyArea()
      Returns whether map scrolling is done by copying pixel areas.
      boolean isDebugGui()
      Returns whether debugging of GUI elements is enabled.
      boolean isFullScreen()
      Returns whether full-screen mode should be enabled.
      void parse​(@NotNull java.lang.String @NotNull [] args)
      Parse command line arguments.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • DEFAULT_SKIN

        @NotNull
        public static final @NotNull java.lang.String DEFAULT_SKIN
        The default skin name.
        See Also:
        Constant Field Values
    • Constructor Detail

      • Options

        public Options()
    • Method Detail

      • parse

        public void parse​(@NotNull
                          @NotNull java.lang.String @NotNull [] args)
        Parse command line arguments.
        Parameters:
        args - the command line arguments
      • getDebugProtocolFilename

        @Nullable
        public @Nullable java.lang.String getDebugProtocolFilename()
        Returns the filename for Crossfire protocol debug logs.
        Returns:
        the filename or null to not log Crossfire protocol messages
      • getDebugKeyboardFilename

        @Nullable
        public @Nullable java.lang.String getDebugKeyboardFilename()
        Returns the filename for keyboard debug logs.
        Returns:
        the filename or null to not log keyboard input
      • getDebugMouseFilename

        @Nullable
        public @Nullable java.lang.String getDebugMouseFilename()
        Returns the filename for mouse debug logs.
        Returns:
        the filename or null to not log mouse input
      • getDebugScreenFilename

        @Nullable
        public @Nullable java.lang.String getDebugScreenFilename()
        Returns the filename for screen debug logs.
        Returns:
        the filename or null to not log screen logs
      • getDebugSoundFilename

        @Nullable
        public @Nullable java.lang.String getDebugSoundFilename()
        Returns the filename for sound debug logs.
        Returns:
        the filename or null to not log sound logs
      • isDebugGui

        public boolean isDebugGui()
        Returns whether debugging of GUI elements is enabled.
        Returns:
        whether debugging of GUI elements is enabled
      • getResolution

        @Nullable
        public @Nullable Resolution getResolution()
        Returns the resolution.
        Returns:
        the resolution or null for default
      • getSkin

        @NotNull
        public @NotNull java.lang.String getSkin()
        Returns the skin name.
        Returns:
        the skin name
      • getTileSize

        public int getTileSize()
        Returns the size of a tile in the map view.
        Returns:
        the tile size in pixels
      • isFullScreen

        public boolean isFullScreen()
        Returns whether full-screen mode should be enabled.
        Returns:
        whether full-screen mode should be enabled
      • getServer

        @Nullable
        public @Nullable java.lang.String getServer()
        Returns the Crossfire server to connect to.
        Returns:
        the server or null for interactive server selection
      • isAvoidCopyArea

        public boolean isAvoidCopyArea()
        Returns whether map scrolling is done by copying pixel areas. If unset, always repaint all map squares.
        Returns:
        whether copying pixel areas is disallowed