This repository has been archived by the owner on Dec 16, 2023. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
248d572
commit a0bb8ee
Showing
7 changed files
with
208 additions
and
316 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
71 changes: 0 additions & 71 deletions
71
src/main/java/doggytalents/common/entity/ai/BerserkerGoal.java
This file was deleted.
Oops, something went wrong.
21 changes: 21 additions & 0 deletions
21
src/main/java/doggytalents/common/entity/ai/BerserkerModeGoal.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
package doggytalents.common.entity.ai; | ||
|
||
import doggytalents.api.feature.EnumMode; | ||
import doggytalents.common.entity.DogEntity; | ||
import net.minecraft.entity.LivingEntity; | ||
import net.minecraft.entity.ai.goal.NearestAttackableTargetGoal; | ||
|
||
public class BerserkerModeGoal<T extends LivingEntity> extends NearestAttackableTargetGoal<T> { | ||
|
||
private final DogEntity dog; | ||
|
||
public BerserkerModeGoal(DogEntity dogIn, Class<T> targetClassIn, boolean checkSight) { | ||
super(dogIn, targetClassIn, checkSight, false); | ||
this.dog = dogIn; | ||
} | ||
|
||
@Override | ||
public boolean shouldExecute() { | ||
return this.dog.isMode(EnumMode.BERSERKER) && this.shouldExecute(); | ||
} | ||
} |
Oops, something went wrong.