Class BoundingBoxes

java.lang.Object
net.bitbylogic.packetblocks.util.BoundingBoxes

public class BoundingBoxes extends Object
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static org.bukkit.util.BoundingBox
    getBox(@NonNull org.bukkit.Material material)
    Retrieves the BoundingBox associated with the specified Material.
    static org.bukkit.util.BoundingBox
    getBoxAt(@NonNull org.bukkit.Material material, @NonNull org.bukkit.Location location)
    Retrieves a BoundingBox at the specified location for the given material.
    static void
    init(@NonNull PacketBlocks plugin)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • BoundingBoxes

      public BoundingBoxes()
  • Method Details

    • init

      public static void init(@NonNull @NonNull PacketBlocks plugin)
    • getBox

      public static org.bukkit.util.BoundingBox getBox(@NonNull @NonNull org.bukkit.Material material)
      Retrieves the BoundingBox associated with the specified Material.
      Parameters:
      material - the material for which the bounding box needs to be retrieved; must not be null
      Returns:
      the bounding box corresponding to the given material, or null if no bounding box is defined
    • getBoxAt

      public static org.bukkit.util.BoundingBox getBoxAt(@NonNull @NonNull org.bukkit.Material material, @NonNull @NonNull org.bukkit.Location location)
      Retrieves a BoundingBox at the specified location for the given material. The method shifts the bounding box of the material to align it with the block location. If the material does not have a bounding box defined, the method returns null.
      Parameters:
      material - the material whose bounding box is to be retrieved, must not be null
      location - the location where the bounding box is to be positioned, must not be null
      Returns:
      the bounding box of the material at the specified location, or null if the material does not have a bounding box