Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 3 additions & 5 deletions Client/game_sa/CGameSA.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -490,9 +490,6 @@ void CGameSA::Reset()

// Restore vehicle model wheel sizes
CModelInfoSA::ResetAllVehiclesWheelSizes();

// Reset the vehicle sun glare effect to default
CVehicleSA::SetVehiclesSunGlareEnable(false);
}
}

Expand Down Expand Up @@ -664,6 +661,7 @@ void CGameSA::ResetCheats()
SetMoonEasterEggEnabled(false);
SetExtraAirResistanceEnabled(true);
SetUnderWorldWarpEnabled(true);
CVehicleSA::SetVehiclesSunGlareEnabled(false);

std::map<std::string, SCheatSA*>::iterator it;
for (it = m_Cheats.begin(); it != m_Cheats.end(); it++)
Expand Down Expand Up @@ -740,12 +738,12 @@ void CGameSA::SetJetpackWeaponEnabled(eWeaponType weaponType, bool bEnabled)
void CGameSA::SetVehicleSunGlareEnabled(bool bEnabled)
{
// State turning will be handled in hooks handler
CVehicleSA::SetVehiclesSunGlareEnable(bEnabled);
CVehicleSA::SetVehiclesSunGlareEnabled(bEnabled);
}

bool CGameSA::IsVehicleSunGlareEnabled()
{
return CVehicleSA::GetVehiclesSunGlareEnable();
return CVehicleSA::GetVehiclesSunGlareEnabled();
}

bool CGameSA::PerformChecks()
Expand Down
4 changes: 2 additions & 2 deletions Client/game_sa/CVehicleSA.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2348,12 +2348,12 @@ void CVehicleSA::StaticSetHooks()
HookInstall(FUNC_CAutomobile_OnVehiclePreRender, (DWORD)HOOK_Vehicle_PreRender, 5);
}

void CVehicleSA::SetVehiclesSunGlareEnable(bool bEnabled)
void CVehicleSA::SetVehiclesSunGlareEnabled(bool bEnabled)
{
m_bVehicleSunGlare = bEnabled;
}

bool CVehicleSA::GetVehiclesSunGlareEnable()
bool CVehicleSA::GetVehiclesSunGlareEnabled()
{
return m_bVehicleSunGlare;
}
Expand Down
4 changes: 2 additions & 2 deletions Client/game_sa/CVehicleSA.h
Original file line number Diff line number Diff line change
Expand Up @@ -774,8 +774,8 @@ class CVehicleSA : public virtual CVehicle, public virtual CPhysicalSA
const CVector* GetDummyPositions() const override { return m_dummyPositions.data(); }

static void StaticSetHooks();
static void SetVehiclesSunGlareEnable(bool bEnabled);
static bool GetVehiclesSunGlareEnable();
static void SetVehiclesSunGlareEnabled(bool bEnabled);
static bool GetVehiclesSunGlareEnabled();

private:
static void SetAutomobileDummyPosition(CAutomobileSAInterface* automobile, eVehicleDummies dummy, const CVector& position);
Expand Down