mirror of
https://github.com/dashr9230/SA-MP.git
synced 2026-10-10 19:53:04 +08:00
[saco] Match CPlayerPed::StopGoggles; retail writes the HasGoggles test out inline
This commit is contained in:
@@ -1070,13 +1070,16 @@ void CPlayerPed::StartGoggles()
|
||||
|
||||
void CPlayerPed::StopGoggles()
|
||||
{
|
||||
if (!m_pPed || !HasGoggles()) return;
|
||||
if (!m_pPed) return;
|
||||
|
||||
m_bGoggleState = FALSE;
|
||||
DWORD dwPedPointer = (DWORD)m_pPed;
|
||||
_asm mov ecx, dwPedPointer
|
||||
_asm mov eax, 0x5E6010
|
||||
_asm call eax
|
||||
// retail writes the HasGoggles test out inline
|
||||
if (m_pPed->dwActiveVision != 0 || m_bGoggleState) {
|
||||
m_bGoggleState = FALSE;
|
||||
DWORD dwPedPointer = (DWORD)m_pPed;
|
||||
_asm mov ecx, dwPedPointer
|
||||
_asm mov eax, 0x5E6010
|
||||
_asm call eax
|
||||
}
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user