From ce1f1e9c348a173d2206f898d502401fcae5feb2 Mon Sep 17 00:00:00 2001 From: ricardoofnl Date: Fri, 4 Sep 2026 20:18:48 +0700 Subject: [PATCH] [saco] Add `FUNC_100B4BE0` and `FUNC_100B4C00`; the first GTA callee cleans its own stack, the second does not --- saco/game/util.cpp | 25 +++++++++++++++++++++++++ saco/game/util.h | 2 ++ 2 files changed, 27 insertions(+) diff --git a/saco/game/util.cpp b/saco/game/util.cpp index b4baee3..1561642 100644 --- a/saco/game/util.cpp +++ b/saco/game/util.cpp @@ -590,6 +590,31 @@ bool FUNC_100B4B50(VECTOR *vecPos) return false; } +//----------------------------------------------------------- + +int FUNC_100B4BE0(int a1, int a2, int a3) +{ + _asm push a3 + _asm push a2 + _asm push a1 + _asm mov edx, 0x59C790 + _asm call edx +} + +//----------------------------------------------------------- + +int FUNC_100B4C00(int a1, int a2, int a3) +{ + _asm push a3 + _asm push a2 + _asm push a1 + _asm mov edx, 0x59C810 + _asm call edx + _asm pop edx + _asm pop edx + _asm pop edx +} + diff --git a/saco/game/util.h b/saco/game/util.h index c5d29ea..b8ed377 100644 --- a/saco/game/util.h +++ b/saco/game/util.h @@ -62,6 +62,8 @@ int FUNC_100B61D0(int a1); // .text:100B61D0 bool FUNC_100B4B50(VECTOR *vecPos); void FUNC_100B4D10(VECTOR *vecOut, MATRIX4X4 *pMatrix, VECTOR *vecOffset); +int FUNC_100B4BE0(int a1, int a2, int a3); // .text:100B4BE0 +int FUNC_100B4C00(int a1, int a2, int a3); // .text:100B4C00 BUILDING_TYPE * GamePool_GetBuilding(); DUMMY_TYPE * GamePool_GetDummy();