Package foundry.veil.impl.resource
Class VeilResourceManagerImpl
java.lang.Object
foundry.veil.impl.resource.VeilResourceManagerImpl
- All Implemented Interfaces:
VeilResourceManager
,AutoCloseable
,org.lwjgl.system.NativeResource
@Internal
public class VeilResourceManagerImpl
extends Object
implements VeilResourceManager, org.lwjgl.system.NativeResource
Manages all veil resources
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
addLoader
(VeilResourceLoader loader) Adds a resource loader to the resource managervoid
addVeilLoaders
(VeilRenderer renderer) net.minecraft.server.packs.resources.ResourceManager
net.minecraft.server.packs.resources.PreparableReloadListener
void
free()
@Nullable VeilResource
<?> getVeilResource
(String namespace, String path) Searches for a veil resource by namespace and path.net.minecraft.server.packs.resources.ResourceManager
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.lwjgl.system.NativeResource
close
Methods inherited from interface foundry.veil.api.resource.VeilResourceManager
getResourceMetadata, getResourceMetadata, getVeilResource, resources
-
Constructor Details
-
VeilResourceManagerImpl
public VeilResourceManagerImpl()
-
-
Method Details
-
addVeilLoaders
-
addLoader
Adds a resource loader to the resource manager -
createReloadListener
public net.minecraft.server.packs.resources.PreparableReloadListener createReloadListener() -
clientResources
public net.minecraft.server.packs.resources.ResourceManager clientResources()- Specified by:
clientResources
in interfaceVeilResourceManager
- Returns:
- The regular client-sided resources in the
assets
folder
-
serverResources
public net.minecraft.server.packs.resources.ResourceManager serverResources()- Specified by:
serverResources
in interfaceVeilResourceManager
- Returns:
- The server-sided resources in the
data
folder
-
getVeilResource
Description copied from interface:VeilResourceManager
Searches for a veil resource by namespace and path.- Specified by:
getVeilResource
in interfaceVeilResourceManager
- Parameters:
namespace
- The namespace to get the resource frompath
- The path of the resource- Returns:
- The resource found or
null
-
free
public void free()- Specified by:
free
in interfaceorg.lwjgl.system.NativeResource
-
getAllPacks
- Returns:
- All pack folders
-