Package net.mcreator.workspace.resources
Class ExternalTexture
java.lang.Object
net.mcreator.workspace.resources.Texture
net.mcreator.workspace.resources.ExternalTexture
A texture loaded from vanilla MC asset archives or from mods downloaded by API plugins.
-
Nested Class Summary
Nested classes/interfaces inherited from class net.mcreator.workspace.resources.Texture
Texture.Dummy
-
Field Summary
Fields inherited from class net.mcreator.workspace.resources.Texture
textureName, textureType
-
Method Summary
Modifier and TypeMethodDescriptionstatic ExternalTexture
getTexture
(Workspace workspace, TextureType textureType, String textureName) Searches in the provided workspace for an externally loaded texture with matching name and type.getTextureIcon
(Workspace workspace) getTexturesOfType
(Workspace workspace, TextureType type) Scans the workspace and collects all the available externally loaded textures of a certain type.static void
invalidateCache
(Workspace workspace)
-
Method Details
-
getTextureIcon
- Specified by:
getTextureIcon
in classTexture
-
getTexture
public static ExternalTexture getTexture(Workspace workspace, TextureType textureType, String textureName) Searches in the provided workspace for an externally loaded texture with matching name and type.- Parameters:
workspace
- The workspace to search in.textureType
- The type of the textures to check.textureName
- The name of the texture to look for.- Returns:
- The vanilla/external texture with the provided name of the specified type.
-
getTexturesOfType
Scans the workspace and collects all the available externally loaded textures of a certain type.- Parameters:
workspace
- The workspace to collect icons for.type
- The type of the textures to collect.- Returns:
- The list of textures from vanilla MC and API mods available in the provided workspace.
-
invalidateCache
-