java.lang.Object
com.minecolonies.core.colony.buildings.modules.settings.StringSetting
com.minecolonies.core.colony.buildings.modules.settings.BuilderModeSetting
All Implemented Interfaces:
ISetting<String>, IStringSetting<String>

public class BuilderModeSetting extends StringSetting
Stores the builder mode setting.
  • Field Details

  • Constructor Details

    • BuilderModeSetting

      public BuilderModeSetting()
      Create the builder mode setting.
    • BuilderModeSetting

      public BuilderModeSetting(List<String> value, int curr)
      Create the builder mode setting.
      Parameters:
      value - the list of possible settings.
      curr - the current setting.
  • Method Details

    • getActualValue

      @NotNull public static @NotNull String getActualValue(@NotNull @NotNull IBuilding building)
    • getDisplayText

      protected net.minecraft.network.chat.Component getDisplayText()
      Description copied from class: StringSetting
      Get the text to render on the button, defaults to the stored index value.
      Overrides:
      getDisplayText in class StringSetting
      Returns:
      the component to render on the button.
    • getToolTipText

      public net.minecraft.network.chat.Component getToolTipText()
      Description copied from interface: ISetting
      Get the tooltip text to render on the button, defaults to null.
      Returns:
      the tooltip component to render on the button.
    • isActive

      public boolean isActive(ISettingsModule module)
      Description copied from interface: ISetting
      Check if this setting is active (provided ISettingsModule.getOptionalSetting(ISettingKey) is used).
      Returns:
      true if the setting is active;
    • isActive

      public boolean isActive(ISettingsModuleView module)
      Description copied from interface: ISetting
      Check if this setting is active (provided ISettingsModule.getOptionalSetting(ISettingKey) is used).
      Returns:
      a component containing a message why this setting is not active, return null if the setting is supposed to be active.
    • getInactiveReason

      @Nullable public @Nullable net.minecraft.network.chat.Component getInactiveReason()
      Description copied from interface: ISetting
      Get the reason why this setting is inactive.
      Returns:
      a component stating why this is inactive, or null if no reason.