templates: Move to 'usercf' instead of 'userpf'

Local (per-user) add-ons to software should reside in "C:\Users\Username\AppData\Local\Programs\Common\", similar to System (all-users) add-ons which reside in "C:\Program Files\Common Files\".

Fixes #1049
This commit is contained in:
Michael Fabian 'Xaymar' Dirks 2023-05-20 16:39:20 +02:00 committed by Xaymar
parent 38d87f6fcf
commit f66fabc5d4

View file

@ -250,11 +250,11 @@ begin
// If this is a User install, register the necessary environment changes.
if (IsUserMode()) then begin
sPluginsPath := ExpandConstant('{userpf}\obs-studio\plugins\%module%\bin\');
sPluginsPath := ExpandConstant('{usercf}\obs-studio\plugins\%module%\bin\');
StringChangeEx(sPluginsPath, '\', '/', True);
RegWriteExpandStringValue(HKEY_CURRENT_USER, 'Environment', 'OBS_PLUGINS_PATH', sPluginsPath);
sPluginsDataPath := ExpandConstant('{userpf}\obs-studio\plugins\%module%\data\');
sPluginsDataPath := ExpandConstant('{usercf}\obs-studio\plugins\%module%\data\');
StringChangeEx(sPluginsDataPath, '\', '/', True);
RegWriteExpandStringValue(HKEY_CURRENT_USER, 'Environment', 'OBS_PLUGINS_DATA_PATH', sPluginsDataPath);
@ -272,7 +272,7 @@ begin
// Default to ProgramData/obs-studio/@PROJECT_NAME@
Result := ExpandConstant('{commonappdata}\obs-studio\plugins\@PROJECT_NAME@');
end else if (IsUserMode()) then begin
Result := ExpandConstant('{userpf}\obs-studio\plugins\@PROJECT_NAME@');
Result := ExpandConstant('{usercf}\obs-studio\plugins\@PROJECT_NAME@');
end else begin
// If a path was given as an argument, use it.
if (Value <> '') then begin