Class CreakingHeartBlockEntity
java.lang.Object
net.neoforged.neoforge.attachment.AttachmentHolder
net.minecraft.world.level.block.entity.BlockEntity
net.minecraft.world.level.block.entity.CreakingHeartBlockEntity
- All Implemented Interfaces:
DebugValueSource,IAttachmentHolder,IBlockEntityExtension
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraft.world.level.block.entity.BlockEntity
BlockEntity.BlockEntityPathElementNested classes/interfaces inherited from class net.neoforged.neoforge.attachment.AttachmentHolder
AttachmentHolder.AsFieldNested classes/interfaces inherited from interface net.minecraft.util.debug.DebugValueSource
DebugValueSource.Registration, DebugValueSource.ValueGetter<T> -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final intstatic final intprivate static final intprivate intprivate Vec3private static final intprivate static final intprivate static final intprivate static final intprivate static final intprivate static final intprivate intprivate static final intprivate static final intprivate static final intprivate intprivate static final intprivate longprivate static final intprivate static final intFields inherited from class net.minecraft.world.level.block.entity.BlockEntity
level, remove, worldPositionFields inherited from class net.neoforged.neoforge.attachment.AttachmentHolder
ATTACHMENTS_NBT_KEY -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate voidintvoidprivate doubleprivate voidemitParticles(ServerLevel pLevel, int pCount, boolean pReverseDirection) intgetUpdateTag(HolderLookup.Provider p_379306_) booleanisProtector(Creaking pCreaking) protected voidloadAdditional(ValueInput p_422490_) voidpreRemoveSideEffects(BlockPos p_394454_, BlockState p_393611_) voidremoveProtector(DamageSource pDamageSource) protected voidsaveAdditional(ValueOutput p_421850_) static voidserverTick(Level pLevel, BlockPos pPos, BlockState pState, CreakingHeartBlockEntity pCreakingHeart) voidsetCreakingInfo(UUID pCreakingUuid) voidsetCreakingInfo(Creaking pCreaking) private static CreakingspawnProtector(ServerLevel pLevel, CreakingHeartBlockEntity pCreakingHeart) private static BlockStateupdateCreakingState(Level pLevel, BlockState pState, BlockPos pPos, CreakingHeartBlockEntity pCreakingHeart) Methods inherited from class net.minecraft.world.level.block.entity.BlockEntity
addEntityType, applyComponents, applyComponentsFromItemStack, applyImplicitComponents, clearRemoved, collectComponents, collectImplicitComponents, components, fillCrashReportCategory, getBlockPos, getBlockState, getLevel, getNameForReporting, getPersistentData, getPosFromTag, getType, hasLevel, isRemoved, isValidBlockState, loadCustomOnly, loadStatic, loadWithComponents, parseCustomNameSafe, problemPath, registerDebugValues, removeComponentsFromTag, removeData, saveCustomOnly, saveCustomOnly, saveWithFullMetadata, saveWithFullMetadata, saveWithId, saveWithoutMetadata, saveWithoutMetadata, setBlockState, setChanged, setChanged, setComponents, setData, setLevel, setRemoved, syncData, triggerEventMethods inherited from class net.neoforged.neoforge.attachment.AttachmentHolder
deserializeAttachments, getData, getExistingDataOrNull, hasAttachments, hasData, serializeAttachmentsMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.neoforged.neoforge.attachment.IAttachmentHolder
getData, getExistingData, getExistingData, getExistingDataOrNull, hasData, removeData, setData, syncDataMethods inherited from interface net.neoforged.neoforge.common.extensions.IBlockEntityExtension
getModelData, handleUpdateTag, hasCustomOutlineRendering, invalidateCapabilities, onChunkUnloaded, onDataPacket, onLoad, requestModelDataUpdate
-
Field Details
-
PLAYER_DETECTION_RANGE
private static final int PLAYER_DETECTION_RANGE- See Also:
-
CREAKING_ROAMING_RADIUS
public static final int CREAKING_ROAMING_RADIUS- See Also:
-
DISTANCE_CREAKING_TOO_FAR
private static final int DISTANCE_CREAKING_TOO_FAR- See Also:
-
SPAWN_RANGE_XZ
private static final int SPAWN_RANGE_XZ- See Also:
-
SPAWN_RANGE_Y
private static final int SPAWN_RANGE_Y- See Also:
-
ATTEMPTS_PER_SPAWN
private static final int ATTEMPTS_PER_SPAWN- See Also:
-
UPDATE_TICKS
private static final int UPDATE_TICKS- See Also:
-
UPDATE_TICKS_VARIANCE
private static final int UPDATE_TICKS_VARIANCE- See Also:
-
HURT_CALL_TOTAL_TICKS
private static final int HURT_CALL_TOTAL_TICKS- See Also:
-
NUMBER_OF_HURT_CALLS
private static final int NUMBER_OF_HURT_CALLS- See Also:
-
HURT_CALL_INTERVAL
private static final int HURT_CALL_INTERVAL- See Also:
-
HURT_CALL_PARTICLE_TICKS
private static final int HURT_CALL_PARTICLE_TICKS- See Also:
-
MAX_DEPTH
private static final int MAX_DEPTH- See Also:
-
MAX_COUNT
private static final int MAX_COUNT- See Also:
-
TICKS_GRACE_PERIOD
private static final int TICKS_GRACE_PERIOD- See Also:
-
NO_CREAKING
-
creakingInfo
-
ticksExisted
private long ticksExisted -
ticker
private int ticker -
emitter
private int emitter -
emitterTarget
-
outputSignal
private int outputSignal
-
-
Constructor Details
-
CreakingHeartBlockEntity
-
-
Method Details
-
serverTick
public static void serverTick(Level pLevel, BlockPos pPos, BlockState pState, CreakingHeartBlockEntity pCreakingHeart) -
updateCreakingState
private static BlockState updateCreakingState(Level pLevel, BlockState pState, BlockPos pPos, CreakingHeartBlockEntity pCreakingHeart) -
distanceToCreaking
private double distanceToCreaking() -
clearCreakingInfo
private void clearCreakingInfo() -
setCreakingInfo
-
setCreakingInfo
-
getCreakingProtector
-
spawnProtector
@Nullable private static Creaking spawnProtector(ServerLevel pLevel, CreakingHeartBlockEntity pCreakingHeart) -
getUpdatePacket
- Overrides:
getUpdatePacketin classBlockEntity
-
getUpdateTag
- Overrides:
getUpdateTagin classBlockEntity
-
creakingHurt
public void creakingHurt() -
spreadResin
-
emitParticles
-
preRemoveSideEffects
- Overrides:
preRemoveSideEffectsin classBlockEntity
-
removeProtector
-
isProtector
-
getAnalogOutputSignal
public int getAnalogOutputSignal() -
computeAnalogOutputSignal
public int computeAnalogOutputSignal() -
loadAdditional
- Overrides:
loadAdditionalin classBlockEntity
-
saveAdditional
- Overrides:
saveAdditionalin classBlockEntity
-