Interface FishHook

All Superinterfaces:
CommandSender, Entity, Metadatable, Nameable, Permissible, PersistentDataHolder, Projectile, ServerOperator

public interface FishHook
extends Projectile
Represents a fishing hook.
  • Method Details

    • getMinWaitTime

      int getMinWaitTime()
      Get the minimum number of ticks one has to wait for a fish biting.

      The default is 100 ticks (5 seconds).
      Note that this is before applying lure.

      Returns:
      Minimum number of ticks one has to wait for a fish biting
    • setMinWaitTime

      void setMinWaitTime​(int minWaitTime)
      Set the minimum number of ticks one has to wait for a fish biting.

      The default is 100 ticks (5 seconds).
      Note that this is before applying lure.

      Parameters:
      minWaitTime - Minimum number of ticks one has to wait for a fish biting
    • getMaxWaitTime

      int getMaxWaitTime()
      Get the maximum number of ticks one has to wait for a fish biting.

      The default is 600 ticks (30 seconds).
      Note that this is before applying lure.

      Returns:
      Maximum number of ticks one has to wait for a fish biting
    • setMaxWaitTime

      void setMaxWaitTime​(int maxWaitTime)
      Set the maximum number of ticks one has to wait for a fish biting.

      The default is 600 ticks (30 seconds).
      Note that this is before applying lure.

      Parameters:
      maxWaitTime - Maximum number of ticks one has to wait for a fish biting
    • getApplyLure

      boolean getApplyLure()
      Get whether the lure enchantment should be applied to reduce the wait time.

      The default is true.
      Lure reduces the wait time by 100 ticks (5 seconds) for each level of the enchantment.

      Returns:
      Whether the lure enchantment should be applied to reduce the wait time
    • setApplyLure

      void setApplyLure​(boolean applyLure)
      Set whether the lure enchantment should be applied to reduce the wait time.

      The default is true.
      Lure reduces the wait time by 100 ticks (5 seconds) for each level of the enchantment.

      Parameters:
      applyLure - Whether the lure enchantment should be applied to reduce the wait time
    • getBiteChance

      @Deprecated double getBiteChance()
      Deprecated.
      has no effect in newer Minecraft versions
      Gets the chance of a fish biting.

      0.0 = No Chance.
      1.0 = Instant catch.

      Returns:
      chance the bite chance
    • setBiteChance

      @Deprecated void setBiteChance​(double chance) throws IllegalArgumentException
      Deprecated.
      has no effect in newer Minecraft versions
      Sets the chance of a fish biting.

      0.0 = No Chance.
      1.0 = Instant catch.

      Parameters:
      chance - the bite chance
      Throws:
      IllegalArgumentException - if the bite chance is not between 0 and 1