Package me.desht.pneumaticcraft.api.heat
Class HeatRegistrationEvent
java.lang.Object
net.minecraftforge.eventbus.api.Event
me.desht.pneumaticcraft.api.heat.HeatRegistrationEvent
@Deprecated(forRemoval=true)
public class HeatRegistrationEvent
extends net.minecraftforge.eventbus.api.Event
Deprecated, for removal: This API element is subject to removal in a future version.
will be removed in 1.19. This should be done purely by datapack now
Fired when block heat properties are loaded from datapacks. This event gives an opportunity to add custom block
heat properties and behaviours in code.
-
Nested Class Summary
Nested classes/interfaces inherited from class net.minecraftforge.eventbus.api.Event
net.minecraftforge.eventbus.api.Event.HasResult, net.minecraftforge.eventbus.api.Event.Result -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final IHeatRegistryDeprecated, for removal: This API element is subject to removal in a future version. -
Constructor Summary
ConstructorsConstructorDescriptionHeatRegistrationEvent(IHeatRegistry registry) Deprecated, for removal: This API element is subject to removal in a future version. -
Method Summary
Modifier and TypeMethodDescriptionvoidregisterBlockExchanger(net.minecraft.world.level.block.Block block, double temperature, double thermalResistance) Deprecated, for removal: This API element is subject to removal in a future version.Register a block as a heat exchanger.Methods inherited from class net.minecraftforge.eventbus.api.Event
getListenerList, getParentListenerList, getPhase, getResult, hasResult, isCancelable, isCanceled, setCanceled, setPhase, setResult, setup
-
Field Details
-
registry
Deprecated, for removal: This API element is subject to removal in a future version.
-
-
Constructor Details
-
HeatRegistrationEvent
Deprecated, for removal: This API element is subject to removal in a future version.
-
-
Method Details
-
registerBlockExchanger
public void registerBlockExchanger(net.minecraft.world.level.block.Block block, double temperature, double thermalResistance) Deprecated, for removal: This API element is subject to removal in a future version.Register a block as a heat exchanger.Note: the preferred way (and only way if you want blockstate transitions) to do this is with datapack recipes. See
data/pneumaticcraft/recipes/block_heat_properties/*.json- Parameters:
block- the blocktemperature- the block's temperaturethermalResistance- the thermal resistance, i.e. how quickly heat will be transferred
-