mirror of
https://github.com/dashr9230/SA-MP.git
synced 2024-12-22 22:47:29 +08:00
[saco] Implement/match CPlayerPed::IsSwimming()
This commit is contained in:
parent
38470a88e1
commit
f829baf38c
@ -79,8 +79,9 @@ typedef struct _PED_TASKS_TYPE
|
|||||||
// Basic Tasks
|
// Basic Tasks
|
||||||
DWORD * pdwDamage;
|
DWORD * pdwDamage;
|
||||||
|
|
||||||
char _gap8[8];
|
char _gap8[4];
|
||||||
|
|
||||||
|
DWORD * pdwSwimWasted;
|
||||||
DWORD * pdwJumpJetPack;
|
DWORD * pdwJumpJetPack;
|
||||||
|
|
||||||
char _gap14[4];
|
char _gap14[4];
|
||||||
|
@ -990,6 +990,17 @@ BOOL CPlayerPed::IsFalling()
|
|||||||
|
|
||||||
//-----------------------------------------------------------
|
//-----------------------------------------------------------
|
||||||
|
|
||||||
|
BOOL CPlayerPed::IsSwimming()
|
||||||
|
{
|
||||||
|
if(m_pPed && !IN_VEHICLE(m_pPed) && m_pPed->Tasks->pdwSwimWasted)
|
||||||
|
{
|
||||||
|
return GetTaskTypeFromTask(m_pPed->Tasks->pdwSwimWasted) == 268;
|
||||||
|
}
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
|
||||||
|
//-----------------------------------------------------------
|
||||||
|
|
||||||
void CPlayerPed::StartJetpack()
|
void CPlayerPed::StartJetpack()
|
||||||
{
|
{
|
||||||
if(!m_pPed) return;
|
if(!m_pPed) return;
|
||||||
|
@ -111,6 +111,7 @@ public:
|
|||||||
BOOL IsJumping();
|
BOOL IsJumping();
|
||||||
BOOL IsFighting();
|
BOOL IsFighting();
|
||||||
BOOL IsFalling();
|
BOOL IsFalling();
|
||||||
|
BOOL IsSwimming();
|
||||||
|
|
||||||
float GetAimZ();
|
float GetAimZ();
|
||||||
void SetAimZ(float fAimZ);
|
void SetAimZ(float fAimZ);
|
||||||
|
Loading…
Reference in New Issue
Block a user