Class MaskUtils
java.lang.Object
me.hsgamer.hscore.minecraft.gui.mask.MaskUtils
The utility class for masks
-
Method Summary
Modifier and TypeMethodDescriptionstatic @NotNull Function<InventoryContext, List<Integer>> Create a background slot functionstatic @NotNull Function<InventoryContext, List<Integer>> createPositionSlots(@NotNull List<InventoryPosition> positions) Create a slot function from the positionsstatic @NotNull Function<InventoryContext, List<Integer>> createPositionSlots(@NotNull InventoryPosition... positions) Create a slot function from the positionsstatic @NotNull Function<InventoryContext, List<Integer>> createStaticSlots(@NotNull Integer... slots) Create a static slot functionstatic @NotNull Function<InventoryContext, List<Integer>> createStaticSlots(@NotNull List<Integer> slots) Create a static slot functionstatic @NotNull Stream<InventoryPosition> generateAreaPositions(@NotNull InventoryPosition position1, @NotNull InventoryPosition position2) Generate the stream of positions in the area between two positionsstatic @NotNull Stream<InventoryPosition> generateOutlinePositions(@NotNull InventoryPosition position1, @NotNull InventoryPosition position2) Get the stream of positions drawing the outline of the area between 2 positions
-
Method Details
-
generateAreaPositions
@NotNull public static @NotNull Stream<InventoryPosition> generateAreaPositions(@NotNull @NotNull InventoryPosition position1, @NotNull @NotNull InventoryPosition position2) Generate the stream of positions in the area between two positions- Parameters:
position1- the first positionposition2- the second position- Returns:
- the stream of positions
-
generateOutlinePositions
@NotNull public static @NotNull Stream<InventoryPosition> generateOutlinePositions(@NotNull @NotNull InventoryPosition position1, @NotNull @NotNull InventoryPosition position2) Get the stream of positions drawing the outline of the area between 2 positions- Parameters:
position1- the first positionposition2- the second position- Returns:
- the stream of positions
-
createPositionSlots
@NotNull public static @NotNull Function<InventoryContext,List<Integer>> createPositionSlots(@NotNull @NotNull List<InventoryPosition> positions) Create a slot function from the positions- Parameters:
positions- the positions- Returns:
- the slot function
-
createPositionSlots
@NotNull public static @NotNull Function<InventoryContext,List<Integer>> createPositionSlots(@NotNull @NotNull InventoryPosition... positions) Create a slot function from the positions- Parameters:
positions- the positions- Returns:
- the slot function
-
createStaticSlots
@NotNull public static @NotNull Function<InventoryContext,List<Integer>> createStaticSlots(@NotNull @NotNull List<Integer> slots) Create a static slot function- Parameters:
slots- the slots- Returns:
- the slot function
-
createStaticSlots
@NotNull public static @NotNull Function<InventoryContext,List<Integer>> createStaticSlots(@NotNull @NotNull Integer... slots) Create a static slot function- Parameters:
slots- the slots- Returns:
- the slot function
-
createBackgroundSlots
Create a background slot function- Returns:
- the slot function
-