From 9ff9f3c28fc66ec3353b65237a9ea9bf535ef9fd Mon Sep 17 00:00:00 2001 From: Bart Trzynadlowski Date: Wed, 14 Sep 2011 23:29:04 +0000 Subject: [PATCH] Now always saves feedback effect configuration (this way, defaults do not have to be defined in multiple places). --- Src/OSD/Windows/DirectInputSystem.cpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/Src/OSD/Windows/DirectInputSystem.cpp b/Src/OSD/Windows/DirectInputSystem.cpp index 614002b..616705e 100644 --- a/Src/OSD/Windows/DirectInputSystem.cpp +++ b/Src/OSD/Windows/DirectInputSystem.cpp @@ -1897,6 +1897,7 @@ void CDirectInputSystem::WriteToINIFile(CINIFile *ini, const char *section) CInputSystem::WriteToINIFile(ini, section); // Only write out those settings which have changed from default + /* if (m_diEffectsGain != 100) ini->Set(section, "DirectInputEffectsGain", m_diEffectsGain); if (m_diConstForceMax != 100) ini->Set(section, "DirectInputConstForceMax", m_diConstForceMax); if (m_diSelfCenterMax != 100) ini->Set(section, "DirectInputSelfCenterMax", m_diSelfCenterMax); @@ -1905,6 +1906,17 @@ void CDirectInputSystem::WriteToINIFile(CINIFile *ini, const char *section) if (m_xiConstForceThreshold != 65) ini->Set(section, "XInputConstForceThreshold", m_xiConstForceThreshold); if (m_xiConstForceMax != 100) ini->Set(section, "XInputConstForceMax", m_xiConstForceMax); if (m_xiVibrateMax != 100) ini->Set(section, "XInputVibrateMax", m_xiVibrateMax); + */ + + // Always write out + ini->Set(section, "DirectInputEffectsGain", m_diEffectsGain); + ini->Set(section, "DirectInputConstForceMax", m_diConstForceMax); + ini->Set(section, "DirectInputSelfCenterMax", m_diSelfCenterMax); + ini->Set(section, "DirectInputFrictionMax", m_diFrictionMax); + ini->Set(section, "DirectInputVibrateMax", m_diVibrateMax); + ini->Set(section, "XInputConstForceThreshold", m_xiConstForceThreshold); + ini->Set(section, "XInputConstForceMax", m_xiConstForceMax); + ini->Set(section, "XInputVibrateMax", m_xiVibrateMax); } bool CDirectInputSystem::Poll()