From 21636f9215e794431933d7689190023e215347de Mon Sep 17 00:00:00 2001 From: MattN-L Date: Sun, 31 Mar 2024 12:44:02 -0400 Subject: [PATCH] Fixed tga animations not displaying --- PCK-Studio/Forms/Editor/TextureAtlasEditor.cs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/PCK-Studio/Forms/Editor/TextureAtlasEditor.cs b/PCK-Studio/Forms/Editor/TextureAtlasEditor.cs index 7d1ed23f..517297dd 100644 --- a/PCK-Studio/Forms/Editor/TextureAtlasEditor.cs +++ b/PCK-Studio/Forms/Editor/TextureAtlasEditor.cs @@ -241,8 +241,11 @@ namespace PckStudio.Forms.Editor if (animationButton.Enabled = _atlasType == "blocks" || _atlasType == "items") { + PckFileData animationFile; + bool hasAnimation = - _pckFile.TryGetValue($"res/textures/{_atlasType}/{dataTile.Tile.InternalName}.png", PckFileType.TextureFile, out var animationFile); + _pckFile.TryGetValue($"res/textures/{_atlasType}/{dataTile.Tile.InternalName}.png", PckFileType.TextureFile, out animationFile) || + _pckFile.TryGetValue($"res/textures/{_atlasType}/{dataTile.Tile.InternalName}.tga", PckFileType.TextureFile, out animationFile); animationButton.Text = hasAnimation ? "Edit Animation" : "Create Animation"; if (playAnimationsToolStripMenuItem.Checked &&