Package net.minecraftforge.fml.common
Annotation Interface Mod.EventBusSubscriber
- Enclosing class:
- Mod
Annotate a class which will be subscribed to an Event Bus at mod construction time.
Defaults to subscribing the current modid to the
MinecraftForge#EVENT_BUS
on both sides.- See Also:
Mod.EventBusSubscriber.Bus
-
Nested Class Summary
-
Optional Element Summary
Modifier and TypeOptional ElementDescriptionSpecify an alternative bus to listen toOptional value, only necessary if this annotation is not on the same class that has a @Mod annotation.net.minecraftforge.api.distmarker.Dist[]
Specify targets to load this event subscriber on.
-
Element Details
-
value
net.minecraftforge.api.distmarker.Dist[] valueSpecify targets to load this event subscriber on. Can be used to avoid loading Client specific events on a dedicated server, for example.- Returns:
- an array of Dist to load this event subscriber on
- Default:
- {CLIENT, DEDICATED_SERVER}
-
modid
String modidOptional value, only necessary if this annotation is not on the same class that has a @Mod annotation. Needed to prevent early classloading of classes not owned by your mod.- Returns:
- a modid
- Default:
- ""
-
bus
Specify an alternative bus to listen to- Returns:
- the bus you wish to listen to
- Default:
- FORGE
-