java.lang.Object
com.blamejared.crafttweaker.natives.entity.type.animal.ExpandAnimal

@ZenRegister public class ExpandAnimal extends Object
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static boolean
    canFallInLove(net.minecraft.world.entity.animal.Animal internal)
    Checks if this Animal can fall in love.
    static boolean
    canMate(net.minecraft.world.entity.animal.Animal internal, net.minecraft.world.entity.animal.Animal other)
    Checks if this Animal can mate with the given Animal.
    static void
    finalizeSpawnChildFromBreeding(net.minecraft.world.entity.animal.Animal internal, net.minecraft.server.level.ServerLevel level, net.minecraft.world.entity.animal.Animal otherParent, net.minecraft.world.entity.AgeableMob child)
    Finalizes the spawning of a child from the breeding of this Animal and the given Animal.
    static int
    getInLoveTime(net.minecraft.world.entity.animal.Animal internal)
    Gets the time in ticks this Animal has been in love.
    static net.minecraft.server.level.ServerPlayer
    getLoveCause(net.minecraft.world.entity.animal.Animal internal)
    Gets the ServerPlayer that caused this Animal to fall in love.
    static boolean
    isFood(net.minecraft.world.entity.animal.Animal internal, net.minecraft.world.item.ItemStack stack)
    Checks if this Animal can eat the ItemStack.
    static boolean
    isInLove(net.minecraft.world.entity.animal.Animal internal)
    Checks if this Animal is in love.
    static void
    resetLove(net.minecraft.world.entity.animal.Animal internal)
    Resets this Animal's love status.
    static void
    setInLove(net.minecraft.world.entity.animal.Animal internal, net.minecraft.world.entity.player.Player loveCause)
    Sets this Animal in love, with the given Player as the cause.
    static void
    setInLoveTime(net.minecraft.world.entity.animal.Animal internal, int inLove)
    Sets the time in ticks this Animal has been in love.
    static void
    spawnChildFromBreeding(net.minecraft.world.entity.animal.Animal internal, net.minecraft.server.level.ServerLevel level, net.minecraft.world.entity.animal.Animal otherParent)
    Spawns a child from the breeding of this Animal and the given Animal.

    Methods inherited from class java.lang.Object

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

    • ExpandAnimal

      public ExpandAnimal()
  • Method Details

    • isFood

      public static boolean isFood(net.minecraft.world.entity.animal.Animal internal, net.minecraft.world.item.ItemStack stack)
      Checks if this Animal can eat the ItemStack.
      Parameters:
      stack - The ItemStack to check.
      Returns:
      True if this Animal can eat the ItemStack, false otherwise.
    • canFallInLove

      public static boolean canFallInLove(net.minecraft.world.entity.animal.Animal internal)
      Checks if this Animal can fall in love.
      Returns:
      True if this Animal can fall in love, false otherwise.
    • setInLove

      public static void setInLove(net.minecraft.world.entity.animal.Animal internal, net.minecraft.world.entity.player.Player loveCause)
      Sets this Animal in love, with the given Player as the cause.
      Parameters:
      loveCause - The Player that caused this Animal to fall in love.
    • setInLoveTime

      public static void setInLoveTime(net.minecraft.world.entity.animal.Animal internal, int inLove)
      Sets the time in ticks this Animal has been in love.
      Parameters:
      inLove - The time in ticks this Animal has been in love.
    • getInLoveTime

      public static int getInLoveTime(net.minecraft.world.entity.animal.Animal internal)
      Gets the time in ticks this Animal has been in love.
      Returns:
      The time in ticks this Animal has been in love.
    • getLoveCause

      public static net.minecraft.server.level.ServerPlayer getLoveCause(net.minecraft.world.entity.animal.Animal internal)
      Gets the ServerPlayer that caused this Animal to fall in love.
      Returns:
      The ServerPlayer that caused this Animal to fall in love.
    • isInLove

      public static boolean isInLove(net.minecraft.world.entity.animal.Animal internal)
      Checks if this Animal is in love.
      Returns:
      True if this Animal is in love, false otherwise.
    • resetLove

      public static void resetLove(net.minecraft.world.entity.animal.Animal internal)
      Resets this Animal's love status.
    • canMate

      public static boolean canMate(net.minecraft.world.entity.animal.Animal internal, net.minecraft.world.entity.animal.Animal other)
      Checks if this Animal can mate with the given Animal.
      Parameters:
      other - The Animal to check.
      Returns:
      True if this Animal can mate with the given Animal, false otherwise.
    • spawnChildFromBreeding

      public static void spawnChildFromBreeding(net.minecraft.world.entity.animal.Animal internal, net.minecraft.server.level.ServerLevel level, net.minecraft.world.entity.animal.Animal otherParent)
      Spawns a child from the breeding of this Animal and the given Animal.
      Parameters:
      level - The ServerLevel to spawn the child in.
      otherParent - The other Animal to mate with.
    • finalizeSpawnChildFromBreeding

      public static void finalizeSpawnChildFromBreeding(net.minecraft.world.entity.animal.Animal internal, net.minecraft.server.level.ServerLevel level, net.minecraft.world.entity.animal.Animal otherParent, net.minecraft.world.entity.AgeableMob child)
      Finalizes the spawning of a child from the breeding of this Animal and the given Animal.
      Parameters:
      level - The ServerLevel to spawn the child in.
      otherParent - The other Animal to mate with.
      child - The AgeableMob to finalize the spawning of.