summaryrefslogtreecommitdiff
path: root/plugins/dfinput/cfg.c
diff options
context:
space:
mode:
authoriCatButler <i.am.catbutler@gmail.com>2018-03-13 17:25:13 +0000
committerGitHub <noreply@github.com>2018-03-13 17:25:13 +0000
commit768332417644451d38ce1a737465656c7cc75de3 (patch)
treee6ca381effb72ccc4161d40f224b817a6631bc03 /plugins/dfinput/cfg.c
parent15fe3782c1375634b7a9bd9bbbadfd75e7b06fed (diff)
parent2d0b10f982e0b835f4b27be26b138703907a4219 (diff)
downloadpcsxr-768332417644451d38ce1a737465656c7cc75de3.tar.gz
Merge pull request #6 from loathingKernel/fix-linux-build
Fix compilation on Linux and add the new setting to the UI
Diffstat (limited to 'plugins/dfinput/cfg.c')
-rwxr-xr-xplugins/dfinput/cfg.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/plugins/dfinput/cfg.c b/plugins/dfinput/cfg.c
index f1d16673..622c3c34 100755
--- a/plugins/dfinput/cfg.c
+++ b/plugins/dfinput/cfg.c
@@ -37,6 +37,8 @@ static void SetDefaultConfig() {
g.cfg.PadDef[0].VisualVibration = 0;
g.cfg.PadDef[1].VisualVibration = 0;
+ g.cfg.PadDef[0].PhysicalVibration = 1;
+ g.cfg.PadDef[1].PhysicalVibration = 1;
// Pad1 keyboard
g.cfg.PadDef[0].KeyDef[DKEY_SELECT].Key = XK_c;
@@ -164,6 +166,8 @@ void LoadPADConfig() {
g.cfg.PadDef[current].Type = atoi(&buf[5]);
} else if (strncmp(buf, "VisualVibration=", 16) == 0) {
g.cfg.PadDef[current].VisualVibration = atoi(&buf[16]);
+ } else if (strncmp(buf, "PhysicalVibration=", 18) == 0) {
+ g.cfg.PadDef[current].PhysicalVibration = atoi(&buf[18]);
} else if (strncmp(buf, "EmuDev=", 7) == 0) {
g.cfg.E.DevNum = atoi(&buf[5]);
} else if (strncmp(buf, "EMU_FASTFORWARDS=", 17) == 0) {
@@ -362,6 +366,7 @@ void SavePADConfig() {
fprintf(fp, "DevNum=%d\n", g.cfg.PadDef[i].DevNum);
fprintf(fp, "Type=%d\n", g.cfg.PadDef[i].Type);
fprintf(fp, "VisualVibration=%d\n", g.cfg.PadDef[i].VisualVibration);
+ fprintf(fp, "PhysicalVibration=%d\n", g.cfg.PadDef[i].PhysicalVibration);
fprintf(fp, "Select=%d,%d,%d\n", g.cfg.PadDef[i].KeyDef[DKEY_SELECT].Key,
g.cfg.PadDef[i].KeyDef[DKEY_SELECT].JoyEvType, g.cfg.PadDef[i].KeyDef[DKEY_SELECT].J.d);