From 375639e84937180c1617b57100ecfa64bd9f5034 Mon Sep 17 00:00:00 2001 From: Sunk <69110309+Sunketchupm@users.noreply.github.com> Date: Mon, 6 Nov 2023 01:40:05 -0500 Subject: [PATCH 1/2] Fix camera bug introduced by a previous PR (#505) * Fix camera bug introduced by a previous PR * Readjust camera collision code --- src/engine/surface_load.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/engine/surface_load.c b/src/engine/surface_load.c index ed7a4dc9..eec3254d 100644 --- a/src/engine/surface_load.c +++ b/src/engine/surface_load.c @@ -392,7 +392,7 @@ static void load_static_surfaces(s16 **data, s16 *vertexData, s16 surfaceType, s struct Surface *surface; s8 room = 0; bool hasForce = surface_has_force(surfaceType); - bool flags = surf_has_no_cam_collision(surfaceType); + s8 flags = surf_has_no_cam_collision(surfaceType) ? SURFACE_FLAG_NO_CAM_COLLISION : 0; numSurfaces = *(*data); *data += 1; @@ -407,7 +407,7 @@ static void load_static_surfaces(s16 **data, s16 *vertexData, s16 surfaceType, s if (surface != NULL) { surface->room = room; surface->type = surfaceType; - surface->flags = (s8) flags; + surface->flags = flags; if (hasForce) { surface->force = *(*data + 3); @@ -671,7 +671,7 @@ void load_object_surfaces(s16** data, s16* vertexData) { hasForce = surface_has_force(surfaceType); - flags = surf_has_no_cam_collision(surfaceType); + flags = surf_has_no_cam_collision(surfaceType) ? SURFACE_FLAG_NO_CAM_COLLISION : 0; flags |= SURFACE_FLAG_DYNAMIC; // The DDD warp is initially loaded at the origin and moved to the proper From 802089f79008e98c6c9426862d2cb59ff9ff0c80 Mon Sep 17 00:00:00 2001 From: Sunk <69110309+Sunketchupm@users.noreply.github.com> Date: Tue, 7 Nov 2023 01:56:05 -0500 Subject: [PATCH 2/2] Fix timer issue with PSC (#509) My last PR didn't seem to account for the race timer so now it does --- mods/personal-starcount-ex.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mods/personal-starcount-ex.lua b/mods/personal-starcount-ex.lua index d9360b06..2a6076cc 100644 --- a/mods/personal-starcount-ex.lua +++ b/mods/personal-starcount-ex.lua @@ -122,7 +122,7 @@ local function set_hud_star_positions(m, height, width) -- Move HUD graphics away from the TIMER HUD if timer_current_value ~= 0 then timer_offset_X = 60 - timer_offset_Y = 17 + timer_offset_Y = -17 end star_counter_offset_X = is_in_cutscenes[m.action] and 22 or 76 @@ -173,7 +173,7 @@ local function set_hud_star_positions(m, height, width) -- Move HUD graphics away from the TIMER HUD if timer_current_value ~= 0 then timer_offset_X = 0 - timer_offset_Y = -10 + timer_offset_Y = 12 end star_counter_offset_X = 76