From 6be5c6f619ec7f483a6d8eb734b0600f8016872c Mon Sep 17 00:00:00 2001 From: Agent X <44549182+AgentXLP@users.noreply.github.com> Date: Mon, 22 Dec 2025 15:11:51 -0500 Subject: [PATCH] Hacky Goddard fix --- src/pc/gfx/gfx_pc.c | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/src/pc/gfx/gfx_pc.c b/src/pc/gfx/gfx_pc.c index a89bcac74..2bb823260 100644 --- a/src/pc/gfx/gfx_pc.c +++ b/src/pc/gfx/gfx_pc.c @@ -25,6 +25,7 @@ #include "game/object_helpers.h" #include "game/rendering_graph_node.h" +#include "menu/intro_geo.h" #include "pc/configfile.h" #include "pc/debug_context.h" @@ -788,8 +789,17 @@ static void OPTIMIZE_O3 gfx_sp_vertex(size_t n_vertices, size_t dest_index, cons for (int32_t i = 0; i < rsp.current_num_lights - 1; i++) { calculate_normal_dir(&rsp.current_lights[i], rsp.current_lights_coeffs[i], applyLightingDir); } - static const Light_t lookat_x = {{0, 0, 0}, 0, {0, 0, 0}, 0, {0, 127, 0}, 0}; - static const Light_t lookat_y = {{0, 0, 0}, 0, {0, 0, 0}, 0, {127, 0, 0}, 0}; + Light_t lookat_x = {{0, 0, 0}, 0, {0, 0, 0}, 0, {0, 127, 0}, 0}; + Light_t lookat_y = {{0, 0, 0}, 0, {0, 0, 0}, 0, {127, 0, 0}, 0}; + // HACK: correct goddard env map shine texture orientation + // the proper fix would be making it so it automatically flips + // if the texture is an intensity alpha + if (gSkipInterpolationTitleScreen) { + lookat_x.dir[0] = 127; + lookat_x.dir[1] = 0; + lookat_y.dir[0] = 0; + lookat_y.dir[1] = 127; + } calculate_normal_dir(&lookat_x, rsp.current_lookat_coeffs[0], applyLightingDir); calculate_normal_dir(&lookat_y, rsp.current_lookat_coeffs[1], applyLightingDir); rsp.lights_changed = false;