Class WaveSummonGoal<T extends net.minecraft.world.entity.Mob & WaveSummoningBoss>
java.lang.Object
net.minecraft.world.entity.ai.goal.Goal
tech.anonymoushacker1279.immersiveweapons.entity.ai.goal.WaveSummonGoal<T>
- Direct Known Subclasses:
CelestialTowerSummonGoal, TheCommanderSummonGoal
public abstract class WaveSummonGoal<T extends net.minecraft.world.entity.Mob & WaveSummoningBoss>
extends net.minecraft.world.entity.ai.goal.Goal
-
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 -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidaddToSpawnQueue(net.minecraft.world.entity.Mob mob, boolean isFodder) Add a mob to the spawn queue.booleancanUse()protected abstract voidprotected intprotected booleanprotected voidspawnEntity(net.minecraft.server.level.ServerLevel level, net.minecraft.world.entity.Mob mob, net.minecraft.core.BlockPos summonPos, boolean isFodder) protected voidspawnEntityParticles(net.minecraft.server.level.ServerLevel level) protected voidspawnFromMobQueue(int amount) Spawn a given amount of mobs from the spawn queue.voidtick()Methods inherited from class net.minecraft.world.entity.ai.goal.Goal
adjustedTickDelay, canContinueToUse, getFlags, getServerLevel, getServerLevel, isInterruptable, reducedTickDelay, requiresUpdateEveryTick, setFlags, start, stop, toString
-
Field Details
-
mob
-
summonedEntityTag
-
mobSpawnQueue
-
waveSpawnCooldown
protected int waveSpawnCooldown
-
-
Constructor Details
-
WaveSummonGoal
-
-
Method Details
-
canUse
public boolean canUse()- Specified by:
canUsein classnet.minecraft.world.entity.ai.goal.Goal
-
tick
public void tick()- Overrides:
tickin classnet.minecraft.world.entity.ai.goal.Goal
-
spawnEntityParticles
protected void spawnEntityParticles(net.minecraft.server.level.ServerLevel level) -
spawnEntity
protected void spawnEntity(net.minecraft.server.level.ServerLevel level, net.minecraft.world.entity.Mob mob, net.minecraft.core.BlockPos summonPos, boolean isFodder) -
addToSpawnQueue
protected void addToSpawnQueue(net.minecraft.world.entity.Mob mob, boolean isFodder) Add a mob to the spawn queue. A wave of entities is not spawned all at once for performance reasons.- Parameters:
mob- theMobto add
-
spawnFromMobQueue
protected void spawnFromMobQueue(int amount) Spawn a given amount of mobs from the spawn queue.- Parameters:
amount- the amount of mobs to spawn
-
getEligibleMobsInArea
protected int getEligibleMobsInArea() -
isWavesPastHalf
protected boolean isWavesPastHalf() -
doWaveSpawnBehavior
protected abstract void doWaveSpawnBehavior()
-