From 0de09167c6ef9adb7407bdc2aafe5c27e01e8b57 Mon Sep 17 00:00:00 2001 From: MegaMech Date: Tue, 12 Mar 2024 07:15:36 -0600 Subject: Update DisplayListFactory.cpp --- src/factories/DisplayListFactory.cpp | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/src/factories/DisplayListFactory.cpp b/src/factories/DisplayListFactory.cpp index 389f8f6..772e8f8 100644 --- a/src/factories/DisplayListFactory.cpp +++ b/src/factories/DisplayListFactory.cpp @@ -358,7 +358,11 @@ std::optional> DListFactory::parse(std::vector> 16) & 0xFF; uint8_t index = 0; uint8_t offset = 0; bool light = false; @@ -372,29 +376,30 @@ std::optional> DListFactory::parse(std::vector> 16) & 0xFF; offset = w1; /* * Only generate lights on the second gsSPLight. * gsSPSetLights1(name) outputs three macros: * - * gsSPNumLights(NUMLIGHTS_1) - * gsSPLight(&name.l[0],1) - * gsSPLight(&name.a,2) <-- This ptr is used to generate the lights + * gsSPNumLights(NUMLIGHTS_1) + * gsSPLight(&name.l[0], G_MV_L0) + * gsSPLight(&name.a, G_MV_L1) <-- This ptr is used to generate the lights */ if (subcommand == GBI(G_MV_L1)) { light = true; } - default: { + case GBIVersion::f3dex2: index = C0(0, 8); offset = C0(8, 8) * 8; if(index == GBI(G_MV_LIGHT)) { light = true; } - } + break; } if(const auto decl = Companion::Instance->GetNodeByAddr(w1); !decl.has_value() && light){ -- cgit v1.2.3