Class MinimumStockModuleView
java.lang.Object
com.minecolonies.api.colony.buildings.modules.AbstractBuildingModuleView
com.minecolonies.core.colony.buildings.moduleviews.MinimumStockModuleView
- All Implemented Interfaces:
IBuildingModuleView,IMinimumStockModuleView
- Direct Known Subclasses:
PostBox.PostBoxMinimumStockModuleView
public class MinimumStockModuleView
extends AbstractBuildingModuleView
implements IMinimumStockModuleView
Client side representation of the minimum stock module.
-
Field Summary
Fields inherited from class com.minecolonies.api.colony.buildings.modules.AbstractBuildingModuleView
buildingView, colonyView -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoiddeserialize(@NotNull net.minecraft.network.RegistryFriendlyByteBuf buf) Read this view from aRegistryFriendlyByteBuf.net.minecraft.network.chat.ComponentgetDesc()Get the lang string for the title.net.minecraft.resources.ResourceLocationGet the resource location of the icon for the module view.getStock()The minimum stock.com.ldtteam.blockui.views.BOWindowGet the matching window for the module.booleanCheck if the warehouse has reached the limit.Methods inherited from class com.minecolonies.api.colony.buildings.modules.AbstractBuildingModuleView
canBeHiredAs, getBuildingView, getColony, getProducer, setBuildingView, setColonyView, setProducerMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.minecolonies.api.colony.buildings.modules.IBuildingModuleView
getBuildingView, getColony, getIcon, getProducer, isPageVisible, setBuildingView, setColonyView, setProducer
-
Constructor Details
-
MinimumStockModuleView
public MinimumStockModuleView()
-
-
Method Details
-
deserialize
public void deserialize(@NotNull @NotNull net.minecraft.network.RegistryFriendlyByteBuf buf) Read this view from aRegistryFriendlyByteBuf.- Specified by:
deserializein interfaceIBuildingModuleView- Parameters:
buf- The buffer to read this view from.
-
getWindow
public com.ldtteam.blockui.views.BOWindow getWindow()Description copied from interface:IBuildingModuleViewGet the matching window for the module.- Specified by:
getWindowin interfaceIBuildingModuleView- Returns:
- the window.
-
getStock
Description copied from interface:IMinimumStockModuleViewThe minimum stock.- Specified by:
getStockin interfaceIMinimumStockModuleView- Returns:
- the stock.
-
hasReachedLimit
public boolean hasReachedLimit()Description copied from interface:IMinimumStockModuleViewCheck if the warehouse has reached the limit.- Specified by:
hasReachedLimitin interfaceIMinimumStockModuleView- Returns:
- true if so.
-
getIconResourceLocation
public net.minecraft.resources.ResourceLocation getIconResourceLocation()Description copied from interface:IBuildingModuleViewGet the resource location of the icon for the module view.- Specified by:
getIconResourceLocationin interfaceIBuildingModuleView- Returns:
- the resource location.
-
getDesc
public net.minecraft.network.chat.Component getDesc()Description copied from interface:IBuildingModuleViewGet the lang string for the title.- Specified by:
getDescin interfaceIBuildingModuleView- Returns:
- the lang string.
-