From 8a8ac6830ead306b6395dbfe9fbb26802ad9c587 Mon Sep 17 00:00:00 2001 From: KillzXGaming Date: Sun, 10 May 2020 11:20:20 -0400 Subject: [PATCH] Quick adjustment to visibility --- .../FileFormats/Pokemon/GFLX/GFBANIM/GFBANM.cs | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/File_Format_Library/FileFormats/Pokemon/GFLX/GFBANIM/GFBANM.cs b/File_Format_Library/FileFormats/Pokemon/GFLX/GFBANIM/GFBANM.cs index 9e23391b..3c447ecb 100644 --- a/File_Format_Library/FileFormats/Pokemon/GFLX/GFBANIM/GFBANM.cs +++ b/File_Format_Library/FileFormats/Pokemon/GFLX/GFBANIM/GFBANM.cs @@ -128,12 +128,13 @@ namespace FirstPlugin { GFBMDL model = null; foreach (var container in ObjectEditor.GetDrawableContainers()) { - if (container.ContainerState == ContainerState.Active) { - foreach (var drawable in container.Drawables) - { - if (drawable is GFBMDL_Render) - model = ((GFBMDL_Render)drawable).GfbmdlFile; - } + foreach (var drawable in container.Drawables) + { + if (!drawable.Visible) + continue; + + if (drawable is GFBMDL_Render) + model = ((GFBMDL_Render)drawable).GfbmdlFile; } } return model;