mirror of
https://github.com/MinecraftForge/MinecraftForge.git
synced 2026-11-12 08:17:35 +00:00
1.21.6 - New EventBus 7
A full rewrite and redesign of the library that offers much better performance, new features and fixes all previous design flaws See the migration guide here: https://gist.github.com/PaintNinja/ad82c224aecee25efac1ea3e2cf19b91 Co-authored-by: Paint_Ninja <PaintNinja@users.noreply.github.com>
This commit is contained in:
642 files changed
+7258
-6187
No files matched your search
@@ -620,7 +620,7 @@ public class GameData {
|
||||
ForgeRegistry<?> reg = STAGING.getRegistry(name);
|
||||
Object2IntMap<ResourceLocation> missingIds = m.getValue();
|
||||
MissingMappingsEvent event = reg.getMissingEvent(name, missingIds);
|
||||
MinecraftForge.EVENT_BUS.post(event);
|
||||
MissingMappingsEvent.BUS.post(event);
|
||||
|
||||
List<MissingMappingsEvent.Mapping<?>> lst = event.getAllMappings(reg.getRegistryKey()).stream()
|
||||
.filter(e -> e.action == MissingMappingsEvent.Action.DEFAULT)
|
||||
@@ -700,7 +700,7 @@ public class GameData {
|
||||
}
|
||||
|
||||
private static void fireRemapEvent(final Map<ResourceLocation, Map<ResourceLocation, IdMappingEvent.IdRemapping>> remaps, final boolean isFreezing) {
|
||||
MinecraftForge.EVENT_BUS.post(new IdMappingEvent(remaps, isFreezing));
|
||||
IdMappingEvent.BUS.post(new IdMappingEvent(remaps, isFreezing));
|
||||
}
|
||||
|
||||
//Has to be split because of generics, Yay!
|
||||
|
||||
Reference in new issue
Block a user