mirror of
https://github.com/dashr9230/SA-MP.git
synced 2024-12-22 14:37:29 +08:00
[saco] Implement/match GetTaskTypeFromTask(...)
This commit is contained in:
parent
24b3ff6039
commit
7e6ec7860f
@ -1376,6 +1376,26 @@ DWORD * GetNextTaskFromTask(DWORD *task)
|
|||||||
|
|
||||||
//-----------------------------------------------------------
|
//-----------------------------------------------------------
|
||||||
|
|
||||||
|
int GetTaskTypeFromTask(DWORD *task)
|
||||||
|
{
|
||||||
|
int i = 0;
|
||||||
|
|
||||||
|
if(!task || *task < 0x800000 || *task > 0x900000) return 0;
|
||||||
|
|
||||||
|
_asm pushad
|
||||||
|
_asm mov edx, task
|
||||||
|
_asm mov ebx, [edx]
|
||||||
|
_asm mov edx, [ebx+10h]
|
||||||
|
_asm mov ecx, task
|
||||||
|
_asm call edx
|
||||||
|
_asm mov i, eax
|
||||||
|
_asm popad
|
||||||
|
|
||||||
|
return i;
|
||||||
|
}
|
||||||
|
|
||||||
|
//-----------------------------------------------------------
|
||||||
|
|
||||||
BOOL __stdcall GameIsEntityOnScreen(DWORD * pdwEnt)
|
BOOL __stdcall GameIsEntityOnScreen(DWORD * pdwEnt)
|
||||||
{
|
{
|
||||||
BOOL bResult = FALSE;
|
BOOL bResult = FALSE;
|
||||||
|
@ -74,4 +74,5 @@ void RemoveColorEmbedsFromString(char *szString);
|
|||||||
UINT GetVehicleSubtypeFromVehiclePtr(VEHICLE_TYPE *pVehicle);
|
UINT GetVehicleSubtypeFromVehiclePtr(VEHICLE_TYPE *pVehicle);
|
||||||
|
|
||||||
DWORD * GetNextTaskFromTask(DWORD *task);
|
DWORD * GetNextTaskFromTask(DWORD *task);
|
||||||
|
int GetTaskTypeFromTask(DWORD *task);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user