From 40d68356391f477bd775cf1f5f4ea5cae23a830e Mon Sep 17 00:00:00 2001 From: Gunnar Beutner Date: Thu, 10 Sep 2026 10:22:06 +0200 Subject: [PATCH 1/3] Take the dissolve alpha minimum in DWORD rather than unsigned long --- code/dropship.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/dropship.cpp b/code/dropship.cpp index 960b13d19..4fc2ccb58 100644 --- a/code/dropship.cpp +++ b/code/dropship.cpp @@ -867,7 +867,7 @@ void Dropship_Screen(void) --j; } - int alpha = std::min(255ul, (_dissolve_rate * timeGetTime() - _dissolve_rate * effect->StartTime) / _dissolve_scale); + int alpha = std::min(255, (_dissolve_rate * timeGetTime() - _dissolve_rate * effect->StartTime) / _dissolve_scale); if (alpha != effect->Alpha || overlap_drawn) { effect->Alpha = alpha; From c40d9ebba4ca7b1e83daf128702b3f59e3d73d44 Mon Sep 17 00:00:00 2001 From: Gunnar Beutner Date: Thu, 10 Sep 2026 10:22:26 +0200 Subject: [PATCH 2/3] Pin the trigger action's Value field to a fixed width --- code/taction.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/taction.h b/code/taction.h index c87a3f454..f7e94bc9a 100644 --- a/code/taction.h +++ b/code/taction.h @@ -133,7 +133,7 @@ class TActionClass : public AbstractClass VoxelAnimType VAnim; CrateType Crate; bool Bool; // Boolean value. - long Value; + int Value; float Float; } Data; From df2212cc1cea4b2367f10af152a209d759d14506 Mon Sep 17 00:00:00 2001 From: Gunnar Beutner Date: Thu, 10 Sep 2026 10:22:32 +0200 Subject: [PATCH 3/3] Format the generated type name the way MSVC's %p does --- code/abstype.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/code/abstype.cpp b/code/abstype.cpp index 4a8beb9e7..65299f007 100644 --- a/code/abstype.cpp +++ b/code/abstype.cpp @@ -21,6 +21,7 @@ #include "savestream.h" #include "vector.h" +#include #include @@ -47,8 +48,8 @@ AbstractTypeClass::AbstractTypeClass(char const * ininame) : GivenName() { if (ininame == NULL) { - char pstr[24]; - sprintf(pstr, "%p", (void *)this); + char pstr[2 * sizeof(void *) + 1]; + sprintf(pstr, "%0*" PRIXPTR, (int)(2 * sizeof(void *)), (uintptr_t)this); IniName = TStringID<24>(pstr); } else { IniName = TStringID<24>(ininame);