diff options
| author | PixelGameWizard <30537551+pixelgamewizard@users.noreply.github.com> | 2024-01-22 20:00:34 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-01-23 02:00:34 +0100 |
| commit | 67a45757309f6aa05851350da316d755222949c7 (patch) | |
| tree | 59f936e060700bc9be0c22ad4a9f43f5ff5ba71b /src/main/java/com | |
| parent | 612169c4a0b78e5e8d224928a4bd0d23d8d63d23 (diff) | |
Clarify purpose of NeoForge.EVENT_BUS.register in ExampleMod class (#32)
Diffstat (limited to 'src/main/java/com')
| -rw-r--r-- | src/main/java/com/example/examplemod/ExampleMod.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/main/java/com/example/examplemod/ExampleMod.java b/src/main/java/com/example/examplemod/ExampleMod.java index 4f50275..86686e8 100644 --- a/src/main/java/com/example/examplemod/ExampleMod.java +++ b/src/main/java/com/example/examplemod/ExampleMod.java @@ -76,7 +76,9 @@ public class ExampleMod // Register the Deferred Register to the mod event bus so tabs get registered CREATIVE_MODE_TABS.register(modEventBus); - // Register ourselves for server and other game events we are interested in + // Register ourselves for server and other game events we are interested in. + // Note that this is necessary if and only if we want *this* class (ExampleMod) to respond directly to events. + // Do not add this line if there are no @SubscribeEvent-annotated functions in this class, like onServerStarting() below. NeoForge.EVENT_BUS.register(this); // Register the item to a creative tab |
