summaryrefslogtreecommitdiff
path: root/src/d/d_ovlp_fade2.cpp
diff options
context:
space:
mode:
authorLagoLunatic <LagoLunatic@users.noreply.github.com>2024-07-14 12:09:08 -0400
committerLagoLunatic <LagoLunatic@users.noreply.github.com>2024-07-14 12:09:08 -0400
commit2a958f1ae8be77c65c9fb31ffeeb4fb06e93463d (patch)
tree5dbf6ca95518003bcf2f0a0b54c5f044c3c7b415 /src/d/d_ovlp_fade2.cpp
parentc81caca6a22d8c38c91cddc989f638e4b582aaf0 (diff)
Fakematch d_ovlp_fade2 weak order
fixes #667
Diffstat (limited to 'src/d/d_ovlp_fade2.cpp')
-rw-r--r--src/d/d_ovlp_fade2.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/d/d_ovlp_fade2.cpp b/src/d/d_ovlp_fade2.cpp
index 8b4c336d..da9c8334 100644
--- a/src/d/d_ovlp_fade2.cpp
+++ b/src/d/d_ovlp_fade2.cpp
@@ -236,6 +236,15 @@ static s32 dOvlpFd2_Create(void* i_this) {
return cPhs_COMPLEATE_e;
}
+// Fakematch. Manually define this template function here to make it non-weak, fixing the weak function ordering.
+template <>
+s8 cLib_calcTimer<s8>(s8* value) {
+ if (*(s8*)value != 0) {
+ *value = *value - 1;
+ }
+ return *value;
+}
+
overlap_method_class l_dOvlpFd2_Method = {
(process_method_func)dOvlpFd2_Create,
(process_method_func)dOvlpFd2_Delete,
@@ -258,6 +267,7 @@ overlap_process_profile_definition g_profile_OVERLAP2 = {
&l_dOvlpFd2_Method,
};
+#if VERSION != VERSION_JPN
overlap_process_profile_definition g_profile_OVERLAP3 = {
fpcLy_ROOT_e,
2,
@@ -271,3 +281,4 @@ overlap_process_profile_definition g_profile_OVERLAP3 = {
0x1E4,
&l_dOvlpFd2_Method,
};
+#endif