Deprecated API
Contents
-
ElementDescriptionUse
Style.withStrikethrough(Boolean)
instead.UseStyle.withUnderlined(Boolean)
instead.To be removed in 1.19. SeeEntity.setRemoved(Entity.RemovalReason)
as a possible replacement.To be removed in 1.19. SeeEntity.setRemoved(Entity.RemovalReason)
as a possible replacement.To be removed in 1.19. SeeEntity.setRemoved(Entity.RemovalReason)
as a possible replacement.To be removed in 1.19. SeeServerLevel.removePlayerImmediately(ServerPlayer, Entity.RemovalReason)
as a possible replacement.Use RenderFogEvent. This event will be removed as the other event has better functionality. Event that allows any feature to customize the fog density the player sees. NOTE: In order to make this event have an effect, you must cancel the eventUse other constructor with all the params. Will be removed in 1.19UseRenderLevelStageEvent
instead for more flexibility and improved compatibility with translucent objects. There is noRenderLevelStageEvent.Stage
that directly replaces this event, instead you must decide which Stage best fits your use case.This event was made redundant by the removal of the screen shifting due to potion indicators in the inventory screen (along with being moved to the right hand side). This has been changed to have no effect, and will be removed in 1.19. SeeScreenEvent.PotionSizeEvent
as a possible alternative instead.to be removed in 1.19, use other onFogRender hook with more paramsThis class has a few issues, mainly MinecraftForge/MinecraftForge#8485. UseForgeSlider
instead.Please use the more general overload.Please use the other more general overload.Please use the other more general overload.TODO Remove in 1.19 - useAbstractMinecart.getPickResult()
insteadOverride and useIForgeBlock.getToolModifiedState(BlockState, UseOnContext, ToolAction, boolean)
insteadTo be removed in 1.20. UseForgeHooks.readAdditionalLevelSaveData(CompoundTag, Path)
instead.UseBlockEvent.BlockToolModificationEvent
and put world-modifying actions behindif (!event.isSimulated())
.The uniqueness of registry super types will not be guaranteed starting in 1.19.The uniqueness of registry super types will not be guaranteed starting in 1.19. UseRegistryObject.create(ResourceLocation, ResourceLocation, String)
.The uniqueness of registry super types will not be guaranteed starting in 1.19. UseRegistryObject.create(ResourceLocation, ResourceLocation, String)
.
-
ClassDescriptionUse RenderFogEvent. This event will be removed as the other event has better functionality. Event that allows any feature to customize the fog density the player sees. NOTE: In order to make this event have an effect, you must cancel the eventUse
RenderLevelStageEvent
instead for more flexibility and improved compatibility with translucent objects. There is noRenderLevelStageEvent.Stage
that directly replaces this event, instead you must decide which Stage best fits your use case.This event was made redundant by the removal of the screen shifting due to potion indicators in the inventory screen (along with being moved to the right hand side). This has been changed to have no effect, and will be removed in 1.19. SeeScreenEvent.PotionSizeEvent
as a possible alternative instead.This class has a few issues, mainly MinecraftForge/MinecraftForge#8485. UseForgeSlider
instead.UseBlockEvent.BlockToolModificationEvent
and put world-modifying actions behindif (!event.isSimulated())
.
-
FieldDescriptionForge: This map is patched out of vanilla code. Listen to
BlockEvent.BlockToolModificationEvent
or overrideIForgeBlock.getToolModifiedState(BlockState, UseOnContext, net.minecraftforge.common.ToolAction, boolean)
.Forge: UseRarity.getStyleModifier()
Subtract 1 fromForgeHooks.getNonPatternItemCount()
to get the maximum non-pattern item indexUseBannerPattern.values()
and get the length from the arraySubtractForgeHooks.getNonPatternItemCount()
fromBannerPattern.values()
-
MethodDescriptionForge: use overload with context.Forge: use
ParticleEngine.render(PoseStack, MultiBufferSource.BufferSource, LightTexture, Camera, float, net.minecraft.client.renderer.culling.Frustum)
with Frustum as additional parameterForge: For internal use only. Use the Register events when registering values.Forge: UseRegisterGameTestsEvent
to register game testsForge: UseRegisterGameTestsEvent
to register game testsForge: UseRegisterGameTestsEvent
to register game testsUseStyle.withObfuscated(Boolean)
instead.UseStyle.withStrikethrough(Boolean)
instead.UseStyle.withUnderlined(Boolean)
instead.To be removed in 1.19. SeeEntity.setRemoved(Entity.RemovalReason)
as a possible replacement.To be removed in 1.19. SeeEntity.setRemoved(Entity.RemovalReason)
as a possible replacement.To be removed in 1.19. SeeEntity.setRemoved(Entity.RemovalReason)
as a possible replacement.To be removed in 1.19. SeeServerLevel.removePlayerImmediately(ServerPlayer, Entity.RemovalReason)
as a possible replacement.Forge: UsePackMetadataSection.getPackFormat(net.minecraft.server.packs.PackType)
instead.Forge: use overload with context.Forge useCreativeModeTab.getBackgroundImage()
insteadForge: useCreativeModeTab.setBackgroundImage(net.minecraft.resources.ResourceLocation)
insteadForge: Use damage source sensitive versionForge: Use damage source sensitive versionForge: callForgeSpawnEggItem.fromEntityType(EntityType)
insteadForge: UseBaseRailBlock.getRailDirection(BlockState, BlockGetter, BlockPos, net.minecraft.world.entity.vehicle.AbstractMinecart)
for enhanced ability If you do change this property be aware that other functions in this/subclasses may break as they can make assumptions about this propertyForge: get burn times by calling ForgeHooks#getBurnTime(ItemStack)net.minecraft.world.level.block.state.BlockBehaviour.tick(BlockState, ServerLevel, BlockPos, Random) CallLevel.blockEntityChangedWithoutNeighborUpdates(BlockPos)
instead. See #9235 for details.net.minecraft.world.level.levelgen.synth.ImprovedNoise.noise(double, double, double, double, double) Forge: useLavaFluid.isFlammable(LevelReader,BlockPos,Direction)
insteadto be removed in 1.19, use other onFogRender hook with more paramsuseIngredient.fromJson(JsonElement)
(Stream)}net.minecraftforge.common.crafting.AbstractIngredient.fromValues(Stream<? extends Ingredient.Value>) useIngredient.of()
useIngredient.of(Stream)
(Stream)}useIngredient.of(TagKey)
(Stream)}useIngredient.of(ItemStack...)
(Stream)}useIngredient.of(ItemLike...)
(Stream)}Please use the more general overload.Please use the other more general overload.Please use the other more general overload.TODO Remove in 1.19 - useAbstractMinecart.getPickResult()
insteadOverride and useIForgeBlock.getToolModifiedState(BlockState, UseOnContext, ToolAction, boolean)
insteadTo be removed in 1.20. UseForgeHooks.readAdditionalLevelSaveData(CompoundTag, Path)
instead.useDistExecutor.safeCallWhenOn(Dist, Supplier)
instead. This remains for advanced use cases.useDistExecutor.safeRunWhenOn(Dist, Supplier)
where possible. Advanced uses only.Forge: For internal use only. Use the Register events when registering values.Forge: For internal use only. Use the Register events when registering values.The uniqueness of registry super types will not be guaranteed starting in 1.19.The uniqueness of registry super types will not be guaranteed starting in 1.19. UseRegistryObject.create(ResourceLocation, ResourceLocation, String)
.The uniqueness of registry super types will not be guaranteed starting in 1.19. UseRegistryObject.create(ResourceLocation, ResourceLocation, String)
.
-
ConstructorDescriptionForge: Use the
mod id variant
Forge: Use themod id variant
Forge: Use themod id variant
Forge: Use themod id variant
Forge: Use themod id variant
Forge: Use themod id variant
Forge: Use themod id variant
Forge: Use the mod id variantForge: use constructor with context.Forge: use constructor with context.Forge: UseForgeSpawnEggItem
instead for suppliersFORGE: Use supplier version insteadUse other constructor with all the params. Will be removed in 1.19
Style.withObfuscated(Boolean)
instead.