Class TrialSpawnerData
java.lang.Object
net.minecraft.world.level.block.entity.trialspawner.TrialSpawnerData
-
Field Summary
Modifier and TypeFieldDescriptionprotected long
private static final int
private SimpleWeightedRandomList
<ItemStack> protected Entity
protected Optional
<ResourceKey<LootTable>> static com.mojang.serialization.MapCodec
<TrialSpawnerData> protected long
protected double
protected double
private static final String
static final String
protected int
private static final int
-
Constructor Summary
ConstructorDescriptionTrialSpawnerData
(Set<UUID> p_312283_, Set<UUID> p_312919_, long p_312537_, long p_311955_, int p_312227_, Optional<SpawnData> p_312562_, Optional<ResourceKey<LootTable>> p_312406_) -
Method Summary
Modifier and TypeMethodDescriptionint
countAdditionalPlayers
(BlockPos p_312262_) (package private) SimpleWeightedRandomList
<ItemStack> getDispensingItems
(ServerLevel p_338857_, TrialSpawnerConfig p_338213_, BlockPos p_338577_) getOrCreateDisplayEntity
(TrialSpawner p_312366_, Level p_312148_, TrialSpawnerState p_311790_) protected SpawnData
getOrCreateNextSpawnData
(TrialSpawner p_312745_, RandomSource p_312242_) double
getOSpin()
double
getSpin()
getUpdateTag
(TrialSpawnerState p_312104_) boolean
hasFinishedSpawningAllMobs
(TrialSpawnerConfig p_311805_, int p_312034_) boolean
hasMobToSpawn
(TrialSpawner p_331432_, RandomSource p_330985_) boolean
boolean
isCooldownFinished
(ServerLevel p_312743_) boolean
isReadyToEjectItems
(ServerLevel p_312692_, float p_312374_, int p_338651_) boolean
isReadyToOpenShutter
(ServerLevel p_312291_, float p_312417_, int p_338634_) boolean
isReadyToSpawnNextMob
(ServerLevel p_311818_, TrialSpawnerConfig p_312100_, int p_312550_) private static long
lowResolutionPosition
(ServerLevel p_338878_, BlockPos p_338542_) void
reset()
void
resetAfterBecomingOminous
(TrialSpawner p_338478_, ServerLevel p_338185_) void
setEntityId
(TrialSpawner p_312044_, RandomSource p_312864_, EntityType<?> p_312415_) private void
transformBadOmenIntoTrialOmen
(Player p_338616_, MobEffectInstance p_338599_) void
tryDetectPlayers
(ServerLevel p_311852_, BlockPos p_312503_, TrialSpawner p_338452_)
-
Field Details
-
TAG_SPAWN_DATA
- See Also:
-
TAG_NEXT_MOB_SPAWNS_AT
- See Also:
-
DELAY_BETWEEN_PLAYER_SCANS
private static final int DELAY_BETWEEN_PLAYER_SCANS- See Also:
-
TRIAL_OMEN_PER_BAD_OMEN_LEVEL
private static final int TRIAL_OMEN_PER_BAD_OMEN_LEVEL- See Also:
-
MAP_CODEC
-
detectedPlayers
-
currentMobs
-
cooldownEndsAt
protected long cooldownEndsAt -
nextMobSpawnsAt
protected long nextMobSpawnsAt -
totalMobsSpawned
protected int totalMobsSpawned -
nextSpawnData
-
ejectingLootTable
-
displayEntity
-
dispensing
-
spin
protected double spin -
oSpin
protected double oSpin
-
-
Constructor Details
-
TrialSpawnerData
public TrialSpawnerData() -
TrialSpawnerData
-
-
Method Details
-
reset
public void reset() -
hasMobToSpawn
-
hasFinishedSpawningAllMobs
-
haveAllCurrentMobsDied
public boolean haveAllCurrentMobsDied() -
isReadyToSpawnNextMob
public boolean isReadyToSpawnNextMob(ServerLevel p_311818_, TrialSpawnerConfig p_312100_, int p_312550_) -
countAdditionalPlayers
-
tryDetectPlayers
-
resetAfterBecomingOminous
-
transformBadOmenIntoTrialOmen
-
isReadyToOpenShutter
-
isReadyToEjectItems
-
isCooldownFinished
-
setEntityId
-
getOrCreateNextSpawnData
-
getOrCreateDisplayEntity
@Nullable public Entity getOrCreateDisplayEntity(TrialSpawner p_312366_, Level p_312148_, TrialSpawnerState p_311790_) -
getUpdateTag
-
getSpin
public double getSpin() -
getOSpin
public double getOSpin() -
getDispensingItems
SimpleWeightedRandomList<ItemStack> getDispensingItems(ServerLevel p_338857_, TrialSpawnerConfig p_338213_, BlockPos p_338577_) -
lowResolutionPosition
-