From 178e3fec7f938cc4d59007e16021157bb62b1a96 Mon Sep 17 00:00:00 2001 From: Lila Date: Wed, 9 Oct 2024 13:55:13 +0100 Subject: [PATCH] Hopefully fix ucode being set --- __init__.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/__init__.py b/__init__.py index 67e66a45..4a84f8c6 100644 --- a/__init__.py +++ b/__init__.py @@ -338,13 +338,17 @@ def upgrade_changed_props(): OOT_ObjectProperties.upgrade_changed_props() for scene in bpy.data.scenes: settings: Fast64Settings_Properties = scene.fast64.settings - if settings.internal_game_update_ver < 2: - set_game_defaults(scene, False) - settings.internal_game_update_ver = 2 + if scene.get("decomp_compatible", False): scene.gameEditorMode = "Homebrew" del scene["decomp_compatible"] + if settings.internal_game_update_ver == 0: # set world defaults, since we default to ucode defaults + set_game_defaults(scene, False) + if settings.internal_game_update_ver <= 1 and scene.gameEditorMode != "Homebrew" and scene.world is not None: + scene.world.rdp_defaults.g_lighting_positional = True # set lighting positional in old/new files + settings.internal_game_update_ver = 2 + settings = scene.fast64.renderSettings light0Color = settings.pop("lightColor", None) if light0Color is not None: