Class ProtectingBlock

java.lang.Object
io.github.thebusybiscuit.slimefun5.api.items.SlimefunItem
io.github.mooy1.infinitylib.machines.MenuBlock
io.github.addoncommunity.galactifun.api.items.ProtectingBlock
All Implemented Interfaces:
io.github.thebusybiscuit.slimefun5.core.attributes.EnergyNetComponent, io.github.thebusybiscuit.slimefun5.core.attributes.HologramOwner, io.github.thebusybiscuit.slimefun5.core.attributes.ItemAttribute, io.github.thebusybiscuit.slimefun5.core.attributes.Placeable
Direct Known Subclasses:
CoolingUnit, IonDisperser, SpaceHeater

public abstract class ProtectingBlock extends io.github.mooy1.infinitylib.machines.MenuBlock implements io.github.thebusybiscuit.slimefun5.core.attributes.EnergyNetComponent, io.github.thebusybiscuit.slimefun5.core.attributes.HologramOwner
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected static final String
     
    protected static final String
     

    Fields inherited from class io.github.mooy1.infinitylib.machines.MenuBlock

    BACKGROUND_ITEM, IDLE_ITEM, INPUT_BORDER, NO_ENERGY_ITEM, NO_ROOM_ITEM, OUTPUT_BORDER, PROCESSING_ITEM

    Fields inherited from class io.github.thebusybiscuit.slimefun5.api.items.SlimefunItem

    addon, disenchantable, enchantable, hidden, recipeOutput, useableInWorkbench
  • Constructor Summary

    Constructors
    Constructor
    Description
    ProtectingBlock(io.github.thebusybiscuit.slimefun5.api.items.SlimefunItemStack item, io.github.thebusybiscuit.slimefun5.api.recipes.RecipeType recipeType, org.bukkit.inventory.ItemStack[] recipe)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected abstract AtmosphericEffect
     
    final io.github.thebusybiscuit.slimefun5.core.networks.energy.EnergyNetComponentType
     
    protected abstract int
     
    protected int[]
     
    protected int[]
     
    abstract int
     
    abstract int
     
    protected void
    onBreak(org.bukkit.event.block.BlockBreakEvent e, me.mrCookieSlime.Slimefun.api.inventory.BlockMenu menu)
     
    protected void
    onNewInstance(me.mrCookieSlime.Slimefun.api.inventory.BlockMenu menu, org.bukkit.block.Block b)
     
    protected void
    onPlace(org.bukkit.event.block.BlockPlaceEvent e, org.bukkit.block.Block b)
     
    protected final void
    setup(me.mrCookieSlime.Slimefun.api.inventory.BlockMenuPreset preset)
     
    protected void
    tick(org.bukkit.block.Block b, me.mrCookieSlime.Slimefun.api.inventory.BlockMenu menu)
     

    Methods inherited from class io.github.mooy1.infinitylib.machines.MenuBlock

    getInputSlots, getTransportSlots, postRegister

    Methods inherited from class io.github.thebusybiscuit.slimefun5.api.items.SlimefunItem

    addItemHandler, addItemSetting, addOfficialWikipage, bakeTranslatedDisplay, callItemHandler, canUse, decorateBakedTemplate, equals, error, getAddon, getBlockTicker, getById, getByItem, getByItem, getDrops, getDrops, getGuideType, getHandlers, getId, getItem, getItemGroup, getItemName, getItemSetting, getItemSettings, getOptionalById, getOptionalByItem, getRecipe, getRecipeOutput, getRecipeType, getResearch, getState, getWikipage, hashCode, hasResearch, info, isDisabled, isDisabledIn, isDisenchantable, isEnchantable, isHidden, isItem, isTicking, isUseableInWorkbench, load, preRegister, register, sendDeprecationWarning, setGuideType, setHidden, setItemGroup, setRecipe, setRecipeOutput, setRecipeType, setResearch, setUseableInWorkbench, setWikiText, toString, warn

    Methods inherited from class Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait

    Methods inherited from interface io.github.thebusybiscuit.slimefun5.core.attributes.EnergyNetComponent

    addCharge, getCapacity, getCharge, getCharge, isChargeable, removeCharge, setCharge

    Methods inherited from interface io.github.thebusybiscuit.slimefun5.core.attributes.HologramOwner

    getHologramOffset, removeHologram, updateHologram

    Methods inherited from interface io.github.thebusybiscuit.slimefun5.core.attributes.ItemAttribute

    getId

    Methods inherited from interface io.github.thebusybiscuit.slimefun5.core.attributes.Placeable

    useVanillaBlockBreaking
  • Field Details

  • Constructor Details

    • ProtectingBlock

      @ParametersAreNonnullByDefault public ProtectingBlock(io.github.thebusybiscuit.slimefun5.api.items.SlimefunItemStack item, io.github.thebusybiscuit.slimefun5.api.recipes.RecipeType recipeType, org.bukkit.inventory.ItemStack[] recipe)
  • Method Details

    • onPlace

      @OverridingMethodsMustInvokeSuper protected void onPlace(@Nonnull org.bukkit.event.block.BlockPlaceEvent e, @Nonnull org.bukkit.block.Block b)
      Overrides:
      onPlace in class io.github.mooy1.infinitylib.machines.MenuBlock
    • onBreak

      @OverridingMethodsMustInvokeSuper protected void onBreak(@Nonnull org.bukkit.event.block.BlockBreakEvent e, @Nonnull me.mrCookieSlime.Slimefun.api.inventory.BlockMenu menu)
      Overrides:
      onBreak in class io.github.mooy1.infinitylib.machines.MenuBlock
    • setup

      protected final void setup(@Nonnull me.mrCookieSlime.Slimefun.api.inventory.BlockMenuPreset preset)
      Specified by:
      setup in class io.github.mooy1.infinitylib.machines.MenuBlock
    • onNewInstance

      @OverridingMethodsMustInvokeSuper protected void onNewInstance(@Nonnull me.mrCookieSlime.Slimefun.api.inventory.BlockMenu menu, @Nonnull org.bukkit.block.Block b)
      Overrides:
      onNewInstance in class io.github.mooy1.infinitylib.machines.MenuBlock
    • getEnergyComponentType

      @Nonnull public final io.github.thebusybiscuit.slimefun5.core.networks.energy.EnergyNetComponentType getEnergyComponentType()
      Specified by:
      getEnergyComponentType in interface io.github.thebusybiscuit.slimefun5.core.attributes.EnergyNetComponent
    • getEnergyRequirement

      protected abstract int getEnergyRequirement()
      Returns:
      energy per Slimefun tick
    • getEffect

      @Nonnull protected abstract AtmosphericEffect getEffect()
    • getProtection

      public abstract int getProtection()
    • getRange

      public abstract int getRange()
    • tick

      protected void tick(@Nonnull org.bukkit.block.Block b, @Nonnull me.mrCookieSlime.Slimefun.api.inventory.BlockMenu menu)
    • getInputSlots

      protected int[] getInputSlots()
      Specified by:
      getInputSlots in class io.github.mooy1.infinitylib.machines.MenuBlock
    • getOutputSlots

      protected int[] getOutputSlots()
      Specified by:
      getOutputSlots in class io.github.mooy1.infinitylib.machines.MenuBlock