mirror of
https://github.com/MinecraftForge/MinecraftForge.git
synced 2026-11-26 15:03:04 +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
@@ -74,10 +74,10 @@ public class DelegatingResourcePack extends AbstractPackResources
|
||||
}
|
||||
|
||||
@Override
|
||||
public Collection<ResourceLocation> getResources(PackType type, String pathIn, String pathIn2, int maxDepth, Predicate<String> filter)
|
||||
public Collection<ResourceLocation> getResources(PackType type, String pathIn, String pathIn2, Predicate<ResourceLocation> filter)
|
||||
{
|
||||
return delegates.stream()
|
||||
.flatMap(r -> r.getResources(type, pathIn, pathIn2, maxDepth, filter).stream())
|
||||
.flatMap(r -> r.getResources(type, pathIn, pathIn2, filter).stream())
|
||||
.collect(Collectors.toList());
|
||||
}
|
||||
|
||||
|
||||
@@ -101,7 +101,7 @@ public class PathResourcePack extends AbstractPackResources
|
||||
}
|
||||
|
||||
@Override
|
||||
public Collection<ResourceLocation> getResources(PackType type, String resourceNamespace, String pathIn, int maxDepth, Predicate<String> filter)
|
||||
public Collection<ResourceLocation> getResources(PackType type, String resourceNamespace, String pathIn, Predicate<ResourceLocation> filter)
|
||||
{
|
||||
try
|
||||
{
|
||||
@@ -110,11 +110,11 @@ public class PathResourcePack extends AbstractPackResources
|
||||
|
||||
return Files.walk(root)
|
||||
.map(root::relativize)
|
||||
.filter(path -> path.getNameCount() <= maxDepth && !path.toString().endsWith(".mcmeta") && path.startsWith(inputPath))
|
||||
.filter(path -> filter.test(path.getFileName().toString()))
|
||||
.filter(path -> !path.toString().endsWith(".mcmeta") && path.startsWith(inputPath))
|
||||
// It is VERY IMPORTANT that we do not rely on Path.toString as this is inconsistent between operating systems
|
||||
// Join the path names ourselves to force forward slashes
|
||||
.map(path -> new ResourceLocation(resourceNamespace, Joiner.on('/').join(path)))
|
||||
.filter(filter)
|
||||
.collect(Collectors.toList());
|
||||
}
|
||||
catch (IOException e)
|
||||
|
||||
@@ -29,8 +29,6 @@ import net.minecraftforge.forgespi.language.IModFileInfo;
|
||||
import net.minecraftforge.forgespi.locating.IModFile;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
import javax.annotation.Nonnull;
|
||||
|
||||
public class ResourcePackLoader {
|
||||
private static Map<IModFile, PathResourcePack> modResourcePacks;
|
||||
|
||||
@@ -57,9 +55,9 @@ public class ResourcePackLoader {
|
||||
{
|
||||
return new PathResourcePack(mf.getFile().getFileName(), mf.getFile().getFilePath()){
|
||||
final IModFile modFile = mf.getFile();
|
||||
@Nonnull
|
||||
@NotNull
|
||||
@Override
|
||||
protected Path resolve(@Nonnull String... paths)
|
||||
protected Path resolve(@NotNull String... paths)
|
||||
{
|
||||
return modFile.findResource(paths);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user