mirror of
https://github.com/MinecraftForge/MinecraftForge.git
synced 2026-11-22 13:09:59 +00:00
Forge 1.19
* Bump pack.mcmeta formats * 1.19 biome modifiers * Mark ClientPlayerNetworkEvent.LoggedOutEvent's getters as nullable * Add docs and package-info to client extension interfaces package * Move RenderBlockOverlayEvent hooks to ForgeHooksClient * Add package-infos to client events package * Rename SoundLoadEvent to SoundEngineLoadEvent This reduces confusion from consumers which may think the name SoundLoadEvent refers to an individual sound being loaded rather than the sound engine. * Document and change SoundLoadEvent to fire on mod bus Previously, it fired on both the mod bus and the Forge bus, which is confusing for consumers. * Delete SoundSetupEvent Looking at its original implementation shows that there isn't an appropriate place in the new sound code to reinsert the event, and the place of 'sound engine/manager initialization event' is taken already by SoundLoadEvent. * Perform some cleanup on client events - Removed nullable annotations from ClientPlayerNetworkEvent - Renamed #getPartialTicks methods to #getPartialTick, to be consistent with vanilla's naming of the partial tick - Cleanup documentation to remove line breaks, use the spelling 'cancelled' over 'canceled', and improve docs on existing and new methods. * Remove EntityEvent.CanUpdate Closes MinecraftForge/MinecraftForge#6394 * Switch to Jetbrains nullability annotations * New PlayLevelSoundEvent; replaces old PlaySoundAtEntityEvent * Remove ForgeWorldPresetScreens * Remove IForgeRegistryEntry * Remove use of List<Throwable> in FML's CompletableFutures * Add docs to mod loading stages, stages, and phases * Gradle 7.4.2 * Use SLF4J in FMLLoader and other subprojects * Switch dynamic versions in subprojects to pinned ones * Switch ForgeRoot and MDK to FG plugin markers * Configure Forge javadoc task The task now uses a custom stylesheet with MCForge elements, and configured to combine the generation from the four FML subprojects (fmlloader, fmlcore, javafmllanguage, mclanguage) and the Forge project into the javadoc output. * Update docs/md files, for 1.19 update and the move away from IRC to Discord. * Make "Potentially dangerous alternative prefix" a debug warning, not info. Co-authored-by: Curle <[email protected]> Co-authored-by: sciwhiz12 <[email protected]> Signed-off-by: SizableShrimp <[email protected]>
This commit is contained in:
1 parent
270e778ac5
commit
4ed9117799
1485 files changed
+14960
-15446
No files matched your search
@@ -27,14 +27,13 @@ import net.minecraftforge.fml.javafmlmod.FMLJavaModLoadingContext;
|
||||
import net.minecraftforge.registries.DeferredRegister;
|
||||
import net.minecraftforge.registries.ForgeRegistries;
|
||||
|
||||
import javax.annotation.Nullable;
|
||||
|
||||
import net.minecraft.world.item.Item.Properties;
|
||||
|
||||
import net.minecraft.world.item.ArmorItem;
|
||||
import net.minecraft.world.item.CreativeModeTab;
|
||||
import net.minecraft.world.item.Item;
|
||||
import net.minecraft.world.item.ItemStack;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
|
||||
@Mod(CustomElytraTest.MOD_ID)
|
||||
@Mod.EventBusSubscriber(bus = Mod.EventBusSubscriber.Bus.MOD, modid = CustomElytraTest.MOD_ID)
|
||||
@@ -100,7 +99,7 @@ public class CustomElytraTest
|
||||
{
|
||||
stack.hurtAndBreak(1, entity, e -> e.broadcastBreakEvent(EquipmentSlot.CHEST));
|
||||
}
|
||||
entity.gameEvent(GameEvent.ELYTRA_FREE_FALL);
|
||||
entity.gameEvent(GameEvent.ELYTRA_GLIDE);
|
||||
}
|
||||
}
|
||||
return true;
|
||||
|
||||
@@ -110,73 +110,67 @@ public class TagBasedToolTypesTest
|
||||
DataGenerator gen = event.getGenerator();
|
||||
ExistingFileHelper existing = event.getExistingFileHelper();
|
||||
|
||||
if (event.includeServer())
|
||||
gen.addProvider(event.includeServer(), new BlockTagsProvider(gen, MODID, existing)
|
||||
{
|
||||
gen.addProvider(new BlockTagsProvider(gen, MODID, existing)
|
||||
@Override
|
||||
protected void addTags()
|
||||
{
|
||||
@Override
|
||||
protected void addTags()
|
||||
{
|
||||
this.tag(MINEABLE_TAG).add(STONE.get());
|
||||
this.tag(REQUIRES_TAG).add(STONE.get());
|
||||
}
|
||||
});
|
||||
this.tag(MINEABLE_TAG).add(STONE.get());
|
||||
this.tag(REQUIRES_TAG).add(STONE.get());
|
||||
}
|
||||
});
|
||||
|
||||
gen.addProvider(new LootTableProvider(gen)
|
||||
gen.addProvider(event.includeServer(), new LootTableProvider(gen)
|
||||
{
|
||||
@Override
|
||||
protected void validate(Map<ResourceLocation, LootTable> map, ValidationContext validationtracker)
|
||||
{
|
||||
@Override
|
||||
protected void validate(Map<ResourceLocation, LootTable> map, ValidationContext validationtracker)
|
||||
{
|
||||
map.forEach((name, table) -> LootTables.validate(validationtracker, name, table));
|
||||
}
|
||||
map.forEach((name, table) -> LootTables.validate(validationtracker, name, table));
|
||||
}
|
||||
|
||||
@Override
|
||||
protected List<Pair<Supplier<Consumer<BiConsumer<ResourceLocation, LootTable.Builder>>>, LootContextParamSet>> getTables()
|
||||
@Override
|
||||
protected List<Pair<Supplier<Consumer<BiConsumer<ResourceLocation, LootTable.Builder>>>, LootContextParamSet>> getTables()
|
||||
{
|
||||
return ImmutableList.of(Pair.of(() ->
|
||||
{
|
||||
return ImmutableList.of(Pair.of(() ->
|
||||
return new BlockLoot()
|
||||
{
|
||||
return new BlockLoot()
|
||||
|
||||
@Override
|
||||
protected Iterable<Block> getKnownBlocks()
|
||||
{
|
||||
return BLOCKS.getEntries().stream().map(Supplier::get).collect(Collectors.toList());
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Iterable<Block> getKnownBlocks()
|
||||
{
|
||||
return BLOCKS.getEntries().stream().map(Supplier::get).collect(Collectors.toList());
|
||||
}
|
||||
@Override
|
||||
protected void addTables()
|
||||
{
|
||||
this.dropSelf(STONE.get());
|
||||
}
|
||||
};
|
||||
}, LootContextParamSets.BLOCK));
|
||||
}
|
||||
});
|
||||
|
||||
@Override
|
||||
protected void addTables()
|
||||
{
|
||||
this.dropSelf(STONE.get());
|
||||
}
|
||||
};
|
||||
}, LootContextParamSets.BLOCK));
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
if (event.includeClient())
|
||||
gen.addProvider(event.includeClient(), new BlockStateProvider(gen, MODID, existing)
|
||||
{
|
||||
gen.addProvider(new BlockStateProvider(gen, MODID, existing)
|
||||
@Override
|
||||
protected void registerStatesAndModels()
|
||||
{
|
||||
@Override
|
||||
protected void registerStatesAndModels()
|
||||
{
|
||||
ModelFile model = models().cubeAll(STONE.get().getRegistryName().getPath(), mcLoc("block/debug"));
|
||||
simpleBlock(STONE.get(), model);
|
||||
simpleBlockItem(STONE.get(), model);
|
||||
}
|
||||
});
|
||||
gen.addProvider(new ItemModelProvider(gen, MODID, existing)
|
||||
ModelFile model = models().cubeAll(STONE.getId().getPath(), mcLoc("block/debug"));
|
||||
simpleBlock(STONE.get(), model);
|
||||
simpleBlockItem(STONE.get(), model);
|
||||
}
|
||||
});
|
||||
gen.addProvider(event.includeClient(), new ItemModelProvider(gen, MODID, existing)
|
||||
{
|
||||
@Override
|
||||
protected void registerModels()
|
||||
{
|
||||
@Override
|
||||
protected void registerModels()
|
||||
{
|
||||
getBuilder(TOOL.get().getRegistryName().getPath())
|
||||
.parent(new UncheckedModelFile("item/generated"))
|
||||
.texture("layer0", mcLoc("item/wooden_pickaxe"));
|
||||
}
|
||||
});
|
||||
}
|
||||
getBuilder(TOOL.getId().getPath())
|
||||
.parent(new UncheckedModelFile("item/generated"))
|
||||
.texture("layer0", mcLoc("item/wooden_pickaxe"));
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user