diff --git a/fast64_internal/oot/oot_model_classes.py b/fast64_internal/oot/oot_model_classes.py index 59b5b5253..5fc3fe771 100644 --- a/fast64_internal/oot/oot_model_classes.py +++ b/fast64_internal/oot/oot_model_classes.py @@ -383,7 +383,15 @@ def processDLName(self, name): except: if name == "gEmptyDL": return None - return name + else: + + def clear_segment_attrs(obj): + for attr_name in dir(obj): + setattr(obj, attr_name, False) + + clear_segment_attrs(self.materialContext.ootMaterial.opaque) + clear_segment_attrs(self.materialContext.ootMaterial.transparent) + return name else: segment = pointer >> 24 if segment >= 0x08 and segment <= 0x0D: @@ -391,7 +399,6 @@ def processDLName(self, name): setattr(self.materialContext.ootMaterial.transparent, "segment" + format(segment, "1X"), True) self.materialChanged = True return None - return name def processTextureName(self, textureName): try: