[saco] Implement and match GameIsEntityOnScreen(...)

This commit is contained in:
RD42 2024-05-05 21:33:51 +08:00
parent 1865de083f
commit bb943ef2a3
2 changed files with 15 additions and 0 deletions

View File

@ -1354,6 +1354,20 @@ int __stdcall GameGetWeaponModelIDFromWeaponID(int iWeaponID)
//----------------------------------------------------------- //-----------------------------------------------------------
BOOL __stdcall GameIsEntityOnScreen(DWORD * pdwEnt)
{
BOOL bResult = FALSE;
_asm mov ecx, pdwEnt
_asm mov edx, 0x534540
_asm call edx
_asm mov bResult, eax
return bResult != FALSE;
}
//-----------------------------------------------------------
void __stdcall SetRadarColor(int nIndex,DWORD dwColor) void __stdcall SetRadarColor(int nIndex,DWORD dwColor)
{ {
if(nIndex < sizeof(dwUseHudColors)) { if(nIndex < sizeof(dwUseHudColors)) {

View File

@ -22,6 +22,7 @@ ENTITY_TYPE * __stdcall GamePool_Object_GetAt(int iID);
PED_TYPE * __stdcall GamePool_FindPlayerPed(); PED_TYPE * __stdcall GamePool_FindPlayerPed();
DWORD __stdcall TranslateColorCodeToRGBA(int iCode); DWORD __stdcall TranslateColorCodeToRGBA(int iCode);
BOOL __stdcall GameIsEntityOnScreen(DWORD * pdwEnt);
void __stdcall InitPlayerPedPtrRecords(); void __stdcall InitPlayerPedPtrRecords();
void __stdcall SetPlayerPedPtrRecord(BYTE bytePlayer, DWORD dwPedPtr); void __stdcall SetPlayerPedPtrRecord(BYTE bytePlayer, DWORD dwPedPtr);
DWORD __stdcall GetPlayerPedPtrRecord(BYTE bytePlayer); DWORD __stdcall GetPlayerPedPtrRecord(BYTE bytePlayer);