mirror of
https://github.com/dashr9230/SA-MP.git
synced 2024-12-23 06:57:31 +08:00
[saco] Implement CPlayerPed::HasGoggles()
This commit is contained in:
parent
4a6bdad74a
commit
c905d1dfb4
@ -78,6 +78,10 @@ typedef struct _PED_TYPE
|
||||
|
||||
PED_TASKS_TYPE *Tasks; // 1148-1152
|
||||
|
||||
char _gap480[128];
|
||||
|
||||
DWORD dwActiveVision; // 1280-1284
|
||||
|
||||
} PED_TYPE;
|
||||
|
||||
//-----------------------------------------------------------
|
||||
@ -94,6 +98,7 @@ typedef struct _VEHICLE_TYPE
|
||||
#define TRAIN_FREIGHT 570
|
||||
#define TRAIN_TRAM 449
|
||||
#define HYDRA 520
|
||||
|
||||
//-----------------------------------------------------------
|
||||
|
||||
// ---- weapon id defines ----
|
||||
|
@ -26,7 +26,7 @@ CPlayerPed::CPlayerPed()
|
||||
field_2DE = 0;
|
||||
field_2E2 = 0;
|
||||
field_48 = 0;
|
||||
field_2E6 = 0;
|
||||
m_bGoggleState = FALSE;
|
||||
field_2C1 = 0;
|
||||
field_2C5 = 0;
|
||||
field_2C9 = 0;
|
||||
@ -45,3 +45,11 @@ CPlayerPed::CPlayerPed()
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------
|
||||
|
||||
BOOL CPlayerPed::HasGoggles()
|
||||
{
|
||||
if (!m_pPed) return FALSE;
|
||||
return (BOOL)(m_pPed->dwActiveVision != 0 || m_bGoggleState);
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------
|
||||
|
@ -13,6 +13,9 @@ struct struc_97
|
||||
class CPlayerPed : public CEntity
|
||||
{
|
||||
public:
|
||||
|
||||
BOOL HasGoggles();
|
||||
|
||||
CPlayerPed();
|
||||
|
||||
int field_48;
|
||||
@ -43,7 +46,7 @@ public:
|
||||
|
||||
int field_2DE;
|
||||
int field_2E2;
|
||||
int field_2E6;
|
||||
BOOL m_bGoggleState;
|
||||
|
||||
char _gap2EA[8];
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user