类 TagsUpdatedEvent

java.lang.Object
net.minecraftforge.eventbus.api.Event
net.minecraftforge.event.TagsUpdatedEvent

public class TagsUpdatedEvent extends net.minecraftforge.eventbus.api.Event
Fired when tags are updated on either server or client. This event can be used to refresh data that depends on tags.
  • 字段详细资料

  • 构造器详细资料

    • TagsUpdatedEvent

      public TagsUpdatedEvent(RegistryAccess registryAccess, boolean fromClientPacket, boolean isIntegratedServerConnection)
  • 方法详细资料

    • getRegistryAccess

      public RegistryAccess getRegistryAccess()
      返回:
      The dynamic registries that have had their tags rebound.
    • getUpdateCause

      public TagsUpdatedEvent.UpdateCause getUpdateCause()
      返回:
      the cause for this tag update
    • shouldUpdateStaticData

      public boolean shouldUpdateStaticData()
      Whether static data (which in single player is shared between server and client thread) should be updated as a result of this event. Effectively this means that in single player only the server-side updates this data.