net.minecraft.block.spawner

public final class TrialSpawnerLogic

net.minecraft.world.level.block.entity.trialspawner.TrialSpawner
net.minecraft.world.level.block.entity.trialspawner.TrialSpawner
net.minecraft.class_8963
net.minecraft.block.spawner.TrialSpawnerLogic

Field summary

Modifier and TypeField
private static final org.slf4j.Logger
LOGGER
LOGGER
field_60372
LOGGER
public static final int
DETECT_PLAYER_SPAWN_BUFFER
DETECT_PLAYER_SPAWN_BUFFER
field_47358
field_47358
private static final int
DEFAULT_TARGET_COOLDOWN_LENGTH
DEFAULT_TARGET_COOLDOWN_LENGTH
field_50179
DEFAULT_COOLDOWN_LENGTH
private static final int
DEFAULT_PLAYER_SCAN_RANGE
DEFAULT_PLAYER_SCAN_RANGE
field_50180
DEFAULT_ENTITY_DETECTION_RANGE
private static final int
MAX_MOB_TRACKING_DISTANCE
MAX_MOB_TRACKING_DISTANCE
field_47359
MAX_ENTITY_DISTANCE
private static final int
MAX_MOB_TRACKING_DISTANCE_SQR
MAX_MOB_TRACKING_DISTANCE_SQR
field_47360
MAX_ENTITY_DISTANCE_SQUARED
private static final float
SPAWNING_AMBIENT_SOUND_CHANCE
SPAWNING_AMBIENT_SOUND_CHANCE
field_47361
SOUND_RATE_PER_TICK
private final TrialSpawnerData
data
data
field_47363
data
private TrialSpawnerLogic$FullConfig
config
config
field_60373
fullConfig
private final TrialSpawnerLogic$TrialSpawner
stateAccessor
stateAccessor
field_47364
trialSpawner
private EntityDetector
playerDetector
playerDetector
field_47365
entityDetector
private final EntityDetector$Selector
entitySelector
entitySelector
field_48864
entitySelector
private boolean
overridePeacefulAndMobSpawnRule
overridePeacefulAndMobSpawnRule
field_47366
forceActivate
private boolean
isOminous
isOminous
field_50185
ominous

Constructor summary

ModifierConstructor
public (TrialSpawnerLogic$FullConfig fullConfig, TrialSpawnerLogic$TrialSpawner trialSpawner, EntityDetector entityDetector, EntityDetector$Selector entitySelector)

Method summary

Modifier and TypeMethod
public TrialSpawnerConfig
activeConfig()
activeConfig()
method_71403()
getConfig()
public TrialSpawnerConfig
normalConfig()
normalConfig()
method_58703()
getNormalConfig()
public TrialSpawnerConfig
ominousConfig()
ominousConfig()
method_58704()
getOminousConfig()
public void
load(ValueInput input)
load(ValueInput input)
method_71404(class_11368 arg0)
readData(ReadView view)
public void
store(ValueOutput output)
store(ValueOutput output)
method_71405(class_11372 arg0)
writeData(WriteView view)
public void
applyOminous(ServerLevel level, BlockPos spawnerPos)
applyOminous(ServerLevel level, BlockPos spawnerPos)
method_58700(class_3218 arg0, class_2338 arg1)
setOminous(ServerWorld world, BlockPos pos)
public void
removeOminous(ServerLevel level, BlockPos spawnerPos)
removeOminous(ServerLevel level, BlockPos spawnerPos)
method_58702(class_3218 arg0, class_2338 arg1)
setNotOminous(ServerWorld world, BlockPos pos)
public boolean
isOminous()
isOminous()
method_58705()
isOminous()
public int
getTargetCooldownLength()
getTargetCooldownLength()
method_58706()
getCooldownLength()
public int
getRequiredPlayerRange()
getRequiredPlayerRange()
method_58707()
getDetectionRadius()
public TrialSpawnerState
getState()
getState()
method_55175()
getSpawnerState()
public TrialSpawnerData
getStateData()
getStateData()
method_55174()
getData()
public void
setState(Level level, TrialSpawnerState state)
setState(Level level, TrialSpawnerState state)
method_55163(class_1937 arg0, class_8967 arg1)
setSpawnerState(World world, TrialSpawnerState spawnerState)
public void
markUpdated()
markUpdated()
method_55176()
updateListeners()
public EntityDetector
getPlayerDetector()
getPlayerDetector()
method_55177()
getEntityDetector()
public EntityDetector$Selector
getEntitySelector()
getEntitySelector()
method_56728()
getEntitySelector()
public boolean
canSpawnInLevel(ServerLevel level)
canSpawnInLevel(ServerLevel level)
method_55162(class_3218 arg0)
canActivate(ServerWorld world)
public Optional<UUID>
spawnMob(ServerLevel level, BlockPos spawnerPos)
spawnMob(ServerLevel level, BlockPos spawnerPos)
method_55158(class_3218 arg0, class_2338 arg1)
trySpawnMob(ServerWorld world, BlockPos pos)
public void
ejectReward(ServerLevel level, BlockPos pos, ResourceKey<LootTable> ejectingLootTable)
ejectReward(ServerLevel level, BlockPos pos, ResourceKey<LootTable> ejectingLootTable)
method_55159(class_3218 arg0, class_2338 arg1, class_5321<class_52> arg2)
ejectLootTable(ServerWorld world, BlockPos pos, RegistryKey<LootTable> lootTable)
public void
tickClient(Level level, BlockPos spawnerPos, boolean isOminous)
tickClient(Level level, BlockPos spawnerPos, boolean isOminous)
method_55165(class_1937 arg0, class_2338 arg1, boolean arg2)
tickClient(World world, BlockPos pos, boolean ominous)
public void
tickServer(ServerLevel serverLevel, BlockPos spawnerPos, boolean isOminous)
tickServer(ServerLevel serverLevel, BlockPos spawnerPos, boolean isOminous)
method_55171(class_3218 arg0, class_2338 arg1, boolean arg2)
tickServer(ServerWorld world, BlockPos pos, boolean ominous)
private static boolean
shouldMobBeUntracked(ServerLevel serverLevel, BlockPos spawnerPos, UUID id)
shouldMobBeUntracked(ServerLevel serverLevel, BlockPos spawnerPos, UUID id)
method_55160(class_3218 arg0, class_2338 arg1, UUID arg2)
shouldRemoveMobFromData(ServerWorld world, BlockPos pos, UUID uuid)
private static boolean
inLineOfSight(Level level, Vec3 origin, Vec3 dest)
inLineOfSight(Level level, Vec3 origin, Vec3 dest)
method_55164(class_1937 arg0, class_243 arg1, class_243 arg2)
hasLineOfSight(World world, Vec3d spawnerPos, Vec3d spawnPos)
public static void
addSpawnParticles(Level level, BlockPos pos, RandomSource random, SimpleParticleType particleType)
addSpawnParticles(Level level, BlockPos pos, RandomSource random, SimpleParticleType particleType)
method_55166(class_1937 arg0, class_2338 arg1, class_5819 arg2, class_2400 arg3)
addMobSpawnParticles(World world, BlockPos pos, Random random, SimpleParticleType particle)
public static void
addBecomeOminousParticles(Level level, BlockPos pos, RandomSource random)
addBecomeOminousParticles(Level level, BlockPos pos, RandomSource random)
method_58701(class_1937 arg0, class_2338 arg1, class_5819 arg2)
addTrialOmenParticles(World world, BlockPos pos, Random random)
public static void
addDetectPlayerParticles(Level level, BlockPos pos, RandomSource random, int data, ParticleOptions type)
addDetectPlayerParticles(Level level, BlockPos pos, RandomSource random, int data, ParticleOptions type)
method_55167(class_1937 arg0, class_2338 arg1, class_5819 arg2, int arg3, class_2394 arg4)
addDetectionParticles(World world, BlockPos pos, Random random, int playerCount, ParticleEffect particle)
public static void
addEjectItemParticles(Level level, BlockPos pos, RandomSource random)
addEjectItemParticles(Level level, BlockPos pos, RandomSource random)
method_55173(class_1937 arg0, class_2338 arg1, class_5819 arg2)
addEjectItemParticles(World world, BlockPos pos, Random random)
public void
overrideEntityToSpawn(EntityType<?> type, Level level)
overrideEntityToSpawn(EntityType<?> type, Level level)
method_65372(class_1299<?> arg0, class_1937 arg1)
setEntityType(EntityType<?> entityType, World world)
public void
setPlayerDetector(PlayerDetector playerDetector)
setPlayerDetector(PlayerDetector playerDetector)
method_55168(class_8962 arg0)
setEntityDetector(EntityDetector detector)
public void
overridePeacefulAndMobSpawnRule()
overridePeacefulAndMobSpawnRule()
method_55178()
forceActivate()