Models shouldn't be hidden by default, as many models have objects that are obviously not hidden but do not have FLGS chunks + objects with children can be hidden, only older versions of Blender automatically hide children when parent is hidden

This commit is contained in:
William Herald Snyder 2022-10-08 21:31:08 -04:00
parent 7b9f5c9cfb
commit b120b74cd4
2 changed files with 2 additions and 3 deletions

View File

@ -73,7 +73,7 @@ class Model:
name: str = "Model"
parent: str = ""
model_type: ModelType = ModelType.NULL
hidden: bool = True
hidden: bool = False
transform: ModelTransform = field(default_factory=ModelTransform)

View File

@ -195,6 +195,5 @@ def extract_scene(filepath: str, scene: Scene):
for model in scene.models:
if model.name in model_map:
obj = model_map[model.name]
if get_is_model_hidden(obj) and len(obj.children) == 0:
obj.hide_set(True)
obj.hide_set(model.hidden or get_is_model_hidden(obj))