forums.PPSSPP.org
Cant get controlconfig to work - Printable Version

+- forums.PPSSPP.org (https://forums.ppsspp.org)
+-- Forum: PPSSPP - Playstation Portable Simulator Suitable for Playing Portably (/forumdisplay.php?fid=1)
+--- Forum: General Discussion and Announcements (/forumdisplay.php?fid=2)
+--- Thread: Cant get controlconfig to work (/showthread.php?tid=13655)



Cant get controlconfig to work - fgeds - 11-02-2014 03:50 AM

okay im trying to set custom keyboard binds for each game. Assuming --controlconfig modifies controls.ini. Ppsspp version is 0.9.9.1.718, win64. Nothing is read-only anywhere.

This works:
C:\Games\ppsspp\PPSSPPWindows64.exe --config="c:\temp\temp-settings.ini"


This doesnt:
C:\Games\ppsspp\PPSSPPWindows64.exe --controlconfig="c:\temp\temp-controls.ini"

In fact adding --controlconfig makes the program ignore ppsspp.ini and ignore any changes made, in both settings and controls and reverts to default after program restart. Its like ppsspp doesnt understand what controlconfig means and is getting confused.


RE: Cant get controlconfig to work - fgeds - 11-02-2014 09:37 AM

okay im computer illiterate and i dont know how i got there but
http:// github.com/hrydgard/ppsspp/blob/master/Windows/main.cpp

line 419, the bolded word shouldnt that be "controlsConfigFilename"?


char configFilename[MAX_PATH] = { 0 };
char controlsConfigFilename[MAX_PATH] = { 0 };
...
std::strncpy(configFilename, tempStr.c_str(), MAX_PATH);
std::strncpy(configFilename, tempStr.c_str(), MAX_PATH);
...
g_Config.Load(configFilename, controlsConfigFilename);


RE: Cant get controlconfig to work - Bigpet - 11-02-2014 11:04 AM

yep, you're right, this is the commit that introduced the copy&paste error: https://github.com/hrydgard/ppsspp/commit/3590352429042b16155c5f7f910efcfc33cf4881 so it's been broken since August 31

If you have a github account you can even fix that via the website. If you don't want to make your own pull-request I can do it for you

Btw. you can link to specific lines as well https://github.com/hrydgard/ppsspp/blob/c83b5c0c16512d8ec440c85a39b0cebca5b5e01e/Windows/main.cpp#L419


RE: Cant get controlconfig to work - fgeds - 11-02-2014 12:08 PM

im not quite into that online stuff.. i did create an account but im afraid of clicking anywhere in such a big project. that would be great if you could make a request.


RE: Cant get controlconfig to work - Bigpet - 11-02-2014 12:31 PM

Alright, but it's not like you could break anything, since you can not change anything directly but merely request that a change should be made. Then a maintainer has to look at those changes and decide whether they're ok or not.

Anyway, here' the pull request I opened: https://github.com/hrydgard/ppsspp/pull/7041


RE: Cant get controlconfig to work - fgeds - 11-02-2014 07:00 PM

Wow that was amazingly fast! Awesome. As for me i dont know c++ so checking a c++ project is nonsensical. and w/o a debugger its ten times more difficult anyway. Look we missed another variable there. I did a pull after your example this time. Tbh I feel a bit ashamed for that kind of changes.


RE: Cant get controlconfig to work - Bigpet - 11-02-2014 07:03 PM

Well, these things happen, especially in hobby projects where testing rigor is not a thing most of the time. I didn't look at the surrounding code and I didn't test it, because I couldn't bother finding valid *.inis to test.