mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/PCK-Studio.git
synced 2026-05-27 05:44:43 +00:00
ResourceCategory - Add 'MobEntityTextures' & 'ItemEntityTextures'
This commit is contained in:
@@ -23,6 +23,8 @@ namespace PckStudio.Internal
|
||||
Unknown = -1,
|
||||
ItemAnimation,
|
||||
BlockAnimation,
|
||||
MobEntityTextures,
|
||||
ItemEntityTextures,
|
||||
ItemAtlas,
|
||||
BlockAtlas,
|
||||
ParticleAtlas,
|
||||
|
||||
@@ -25,12 +25,14 @@ namespace PckStudio.Internal
|
||||
internal sealed class ResourceLocation
|
||||
{
|
||||
private static List<ResourceLocation> ResourceGroups = new List<ResourceLocation>();
|
||||
private static readonly ResourceLocation Unknown = new ResourceLocation(string.Empty, ResourceCategory.Unknown, 1);
|
||||
private static readonly ResourceLocation Unknown = new ResourceLocation(string.Empty, ResourceCategory.Unknown, -1);
|
||||
|
||||
private static readonly Dictionary<string, ResourceLocation> _categoryLookUp = new Dictionary<string, ResourceLocation>()
|
||||
{
|
||||
["textures/items"] = new ResourceLocation("textures/items", ResourceCategory.ItemAnimation, 16, isGroup: true),
|
||||
["textures/blocks"] = new ResourceLocation("textures/blocks", ResourceCategory.BlockAnimation, 16, isGroup: true),
|
||||
["mob"] = new ResourceLocation("mob", ResourceCategory.MobEntityTextures, 1, isGroup: true),
|
||||
["item"] = new ResourceLocation("item", ResourceCategory.ItemEntityTextures, 1, isGroup: true),
|
||||
["terrain.png"] = new ResourceLocation("terrain.png", ResourceCategory.BlockAtlas, 16),
|
||||
["items.png"] = new ResourceLocation("items.png", ResourceCategory.ItemAtlas, 16),
|
||||
["particles.png"] = new ResourceLocation("particles.png", ResourceCategory.ParticleAtlas, 16),
|
||||
@@ -49,7 +51,8 @@ namespace PckStudio.Internal
|
||||
{
|
||||
ResourceCategory.ItemAnimation => _categoryLookUp["textures/items"].ToString(),
|
||||
ResourceCategory.BlockAnimation => _categoryLookUp["textures/blocks"].ToString(),
|
||||
ResourceCategory.BlockAtlas => "res/terrain.png",
|
||||
ResourceCategory.MobEntityTextures => _categoryLookUp["mob"].ToString(),
|
||||
ResourceCategory.ItemEntityTextures => _categoryLookUp["item"].ToString(),
|
||||
ResourceCategory.BlockAtlas => _categoryLookUp["terrain.png"].ToString(),
|
||||
ResourceCategory.ItemAtlas => _categoryLookUp["items.png"].ToString(),
|
||||
ResourceCategory.ParticleAtlas => _categoryLookUp["particles.png"].ToString(),
|
||||
|
||||
Reference in New Issue
Block a user