[saco] Implement/match FUNC_10015650; writing the abs difference as >= keeps the subtract order and the test ah, 1 form

This commit is contained in:
ricardoofnl committed 2026-09-05 08:45:38 +07:00
1 parent 809df262a3
commit b87030da7a
3 files changed
+34

No files matched your search

+1
View File
@@ -85,6 +85,7 @@ public:
void FUNC_100B7090(int a1); // .text:100B7090
void FUNC_100B7840(int a1); // .text:100B7840
void FUNC_100B7900(float fT); // .text:100B7900
void FUNC_100B81A0(); // .text:100B81A0
void FUNC_100B81F0(); // .text:100B81F0
void FUNC_100B8150(char *szText); // .text:100B8150
+32
View File
@@ -404,6 +404,38 @@ void CRemotePlayer::FUNC_10017260(BYTE *pSync, int iTime)
//----------------------------------------------------
void CRemotePlayer::FUNC_10015650(MATRIX4X4 *pMat, VECTOR *pMoveSpeed, float fT)
{
int bTeleport = 0;
if(!m_pPlayerPed) return;
if(!field_1E1) return;
MATRIX4X4 mat;
VECTOR vecMove;
float fDiff;
field_1E1->GetMatrix(&mat);
if(pMat->pos.X >= mat.pos.X) fDiff = pMat->pos.X - mat.pos.X;
else fDiff = mat.pos.X - pMat->pos.X;
if(fDiff > 10.0f) bTeleport = 1;
if(pMat->pos.Y >= mat.pos.Y) fDiff = pMat->pos.Y - mat.pos.Y;
else fDiff = mat.pos.Y - pMat->pos.Y;
if(fDiff > 10.0f || bTeleport)
field_1E1->TeleportTo(pMat->pos.X, pMat->pos.Y, pMat->pos.Z);
field_1E1->GetMoveSpeedVector(&vecMove);
vecMove.X = pMoveSpeed->X;
vecMove.Y = pMoveSpeed->Y;
vecMove.Z = pMoveSpeed->Z;
field_1E1->SetMoveSpeedVector(vecMove);
field_1E1->FUNC_100B7900(fT);
}
//----------------------------------------------------
void CRemotePlayer::FUNC_10017340(BYTE *pSync, int iTime)
{
if(iTime && (iTime - field_1BD) < 0) return;
+1
View File
@@ -86,6 +86,7 @@ public:
void FUNC_100148F0(); // .text:100148F0
void FUNC_10014FF0(); // .text:10014FF0
void FUNC_10017260(BYTE *pSync, int iTime); // .text:10017260
void FUNC_10015650(MATRIX4X4 *pMat, VECTOR *pMoveSpeed, float fT); // .text:10015650
void FUNC_10017340(BYTE *pSync, int iTime); // .text:10017340
void FUNC_10017440(BYTE *pSync); // .text:10017440
void FUNC_10014800(); // .text:10014800