Package com.simibubi.create.api.event


package com.simibubi.create.api.event
  • Classes
    Class
    Description
    Event that is fired just before a SmartBlockEntity is being deserialized
    Also if a new one is placed
    Use it to attach a new BlockEntityBehaviour or replace existing ones (with caution)

    Actual setup of the behaviours internal workings and data should be done in BlockEntityBehaviour#read() and BlockEntityBehaviour#initialize() respectively.

    Because of the earliness of this event, the added behaviours will have access to the initial NBT read (unless the BE was placed, not loaded), thereby allowing block entities to store and retrieve data for injected behaviours.

    Example:
    This Event is fired when two fluids meet in a pipe (PipeCollisionEvent.Flow)
    or when a fluid in a pipe meets with a fluid in the world (PipeCollisionEvent.Spill).

    If it is not null, the event's BlockState will be placed in world after firing.