Class BlockUtils

java.lang.Object
io.github.sefiraat.slimetinker.utils.BlockUtils

public final class BlockUtils extends Object
  • Method Summary

    Modifier and Type
    Method
    Description
    static void
    fakePower(org.bukkit.block.Block block)
     
    static void
    fakeUnPower(org.bukkit.block.Block block)
     
    static Map<org.bukkit.Location,Boolean>
     
    static org.bukkit.block.BlockFace
    getTargetedBlockFace(org.bukkit.entity.Player player)
    Credits : https://www.spigotmc.org/threads/getting-the-blockface-of-a-targeted-block.319181/ Gets the BlockFace of the block the player is currently targeting.
    static boolean
    isPlaced(org.bukkit.block.Block block)
     
    static boolean
    isValidBreakEvent(org.bukkit.block.Block block, org.bukkit.entity.Player player)
     

    Methods inherited from class java.lang.Object

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

    • isValidBreakEvent

      public static boolean isValidBreakEvent(org.bukkit.block.Block block, org.bukkit.entity.Player player)
    • isPlaced

      public static boolean isPlaced(org.bukkit.block.Block block)
    • getTargetedBlockFace

      public static org.bukkit.block.BlockFace getTargetedBlockFace(org.bukkit.entity.Player player)
      Credits : https://www.spigotmc.org/threads/getting-the-blockface-of-a-targeted-block.319181/ Gets the BlockFace of the block the player is currently targeting.
      Parameters:
      player - the player's whos targeted blocks BlockFace is to be checked.
      Returns:
      the BlockFace of the targeted block, or null if the targeted block is non-occluding.
    • fakePower

      public static void fakePower(org.bukkit.block.Block block)
    • fakeUnPower

      public static void fakeUnPower(org.bukkit.block.Block block)
    • getStateMap

      public static Map<org.bukkit.Location,Boolean> getStateMap()