diff --git a/saco/game/util.cpp b/saco/game/util.cpp index 9f7d2ec..b430805 100644 --- a/saco/game/util.cpp +++ b/saco/game/util.cpp @@ -467,6 +467,26 @@ struc_13 * __stdcall FUNC_100B43D0(BYTE bytePlayer) //----------------------------------------------------------- +BYTE __stdcall FUNC_100B43F0(DWORD *pdwRenderWare) +{ + BYTE x = 0; + while(x != PLAYER_PED_SLOTS) + { + ENTITY_TYPE *pEntity = (ENTITY_TYPE *)dwPlayerPedPtrs[x]; + if(pEntity) + { + if(pEntity->pdwRenderWare) + { + if(pEntity->pdwRenderWare == pdwRenderWare) + return x; + } + } + x++; + } + return 0; +} + +//----------------------------------------------------------- diff --git a/saco/game/util.h b/saco/game/util.h index ae04259..5001a17 100644 --- a/saco/game/util.h +++ b/saco/game/util.h @@ -40,6 +40,7 @@ DWORD __stdcall GetPlayerPedPtrRecord(BYTE bytePlayer); BYTE __stdcall FindPlayerNumFromPedPtr(DWORD dwPedPtr); void __stdcall FUNC_100B4390(BYTE bytePlayer, DWORD a2, DWORD a3, DWORD a4, DWORD a5); struc_13 * __stdcall FUNC_100B43D0(BYTE bytePlayer); +BYTE __stdcall FUNC_100B43F0(DWORD *pdwRenderWare); float __stdcall SquaredDistanceBetweenHorizontalPoints(float x1, float y1, float x2, float y2); float DistanceBetweenHorizontalPoints(float x1, float y1, float x2, float y2); float DistanceBetweenPoints(float x1, float y1, float z1, float x2, float y2, float z2);