[saco] Implement/match CPlayerPed::IsInJetpackMode()

This commit is contained in:
RD42 2024-08-11 23:34:43 +08:00
parent 9fc8409232
commit 3bb1a5c63d
2 changed files with 16 additions and 0 deletions

View File

@ -432,6 +432,20 @@ void CPlayerPed::SetMoney(int iAmount)
//-----------------------------------------------------------
BOOL CPlayerPed::IsInJetpackMode()
{
if(!m_pPed || IN_VEHICLE(m_pPed)) return FALSE;
if(m_pPed->Tasks->pdwJumpJetPack == NULL) return FALSE;
DWORD dwJmpVtbl = m_pPed->Tasks->pdwJumpJetPack[0];
if(dwJmpVtbl == 0x8705C4) return TRUE;
return FALSE;
}
//-----------------------------------------------------------
void CPlayerPed::StartGoggles()
{
if (HasGoggles()) return;

View File

@ -53,6 +53,8 @@ public:
void SetImmunities(BOOL bBullet, BOOL bFire, BOOL bExplosion, BOOL bDamage, BOOL bUnknown);
BOOL IsInJetpackMode();
void StartGoggles();
void StopGoggles();
BOOL HasGoggles();