net.minecraft.entity.ai.goal.Goal Java Examples

The following examples show how to use net.minecraft.entity.ai.goal.Goal. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: TemptBirdGoal.java    From the-hallow with MIT License 5 votes vote down vote up
public TemptBirdGoal(MobEntityWithAi mobEntityWithAi, double speed, boolean canBeScared, Ingredient food) {
	this.mob = mobEntityWithAi;
	this.speed = speed;
	this.food = food;
	this.canBeScared = canBeScared;
	this.setControls(EnumSet.of(Goal.Control.MOVE, Goal.Control.LOOK));
	if (!(mobEntityWithAi.getNavigation() instanceof BirdNavigation)) {
		throw new IllegalArgumentException("Unsupported mob type for TemptBirdGoal");
	}
}
 
Example #2
Source File: MobEntityMixin.java    From fabric-carpet with MIT License 4 votes vote down vote up
@Override
public Map<String, Goal> getTemporaryTasks()
{
    return temporaryTasks;
}
 
Example #3
Source File: SlimeMerger.java    From Survivalist with BSD 3-Clause "New" or "Revised" License 4 votes vote down vote up
public MergeWithNearbySlimesGoal(SlimeEntity slimeIn)
{
    this.slime = slimeIn;
    this.setMutexFlags(EnumSet.of(Goal.Flag.LOOK));
    this.sorter = new Sorter(slimeIn);
}
 
Example #4
Source File: MobEntityInterface.java    From fabric-carpet with MIT License votes vote down vote up
Map<String, Goal> getTemporaryTasks();