Class MinionCopyTargetGoal

java.lang.Object
net.minecraft.world.entity.ai.goal.Goal
net.minecraft.world.entity.ai.goal.target.TargetGoal
com.binaris.wizardry.content.entity.goal.MinionCopyTargetGoal

public class MinionCopyTargetGoal extends net.minecraft.world.entity.ai.goal.target.TargetGoal
Goal that helps to copy the owner's target for the minion. This is useful when the owner is a mob, allowing to quickly copy the target of the owner and helping it to attack the same target as the owner.

This checks if the minion is actually summoned and if the owner is a mob, then it checks if the mob owner has a target and if that target can be attacked by the minion.

  • Nested Class Summary

    Nested classes/interfaces inherited from class net.minecraft.world.entity.ai.goal.Goal

    net.minecraft.world.entity.ai.goal.Goal.Flag
  • Field Summary

    Fields inherited from class net.minecraft.world.entity.ai.goal.target.TargetGoal

    mob, mustSee, targetMob, unseenMemoryTicks
  • Constructor Summary

    Constructors
    Constructor
    Description
    MinionCopyTargetGoal(net.minecraft.world.entity.Mob mob, MinionData data)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
     
    boolean
     
    void
     

    Methods inherited from class net.minecraft.world.entity.ai.goal.target.TargetGoal

    canAttack, getFollowDistance, setUnseenMemoryTicks, stop

    Methods inherited from class net.minecraft.world.entity.ai.goal.Goal

    adjustedTickDelay, getFlags, isInterruptable, reducedTickDelay, requiresUpdateEveryTick, setFlags, tick, toString

    Methods inherited from class java.lang.Object

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

    • MinionCopyTargetGoal

      public MinionCopyTargetGoal(net.minecraft.world.entity.Mob mob, MinionData data)
  • Method Details

    • canContinueToUse

      public boolean canContinueToUse()
      Overrides:
      canContinueToUse in class net.minecraft.world.entity.ai.goal.target.TargetGoal
    • canUse

      public boolean canUse()
      Specified by:
      canUse in class net.minecraft.world.entity.ai.goal.Goal
    • start

      public void start()
      Overrides:
      start in class net.minecraft.world.entity.ai.goal.target.TargetGoal