View Single Post
  #2  
Old 01-11-2016, 00:41
edward99 edward99 is offline
Banned
 
Join Date: Aug 2015
Location: India
Posts: 58
Thanks: 4
Thanked 12 Times in 6 Posts
edward99 is on a distinguished road
#define SAVES1 "{userappdata}\Ubisoft"
;#define SAVES2 "{userdocs}\BioWare\Mass Effect"
;#define SAVES3 "{userdocs}\BioWare\Mass Effect"

[CustomMessages]
#ifdef SAVES1
del=Do you want to delete saved games?
#endif



#ifdef SAVES1
procedure CurUninstallStepChanged(CurUninstallStep: TUninstallStep);
begin
if CurUninstallStep = usUninstall then
begin
if DirExists(ExpandConstant('{#SAVES1}'))
#ifdef SAVES2
or DirExists(ExpandConstant('{#SAVES2}'))
#endif
#ifdef SAVES3
or DirExists(ExpandConstant('{#SAVES3}'))
#endif
then
begin
if MsgBox(ExpandConstant('{cm:del}'),mbconfirmation, mb_yesno) = IDYES then
begin
DelTree(ExpandConstant('{#SAVES1}'), True, True, True);
#ifdef SAVES2
DelTree(ExpandConstant('{#SAVES2}'), True, True, True);
#endif
#ifdef SAVES3
DelTree(ExpandConstant('{#SAVES3}'), True, True, True);
#endif
end;
end;
end;
end;
#endif
Reply With Quote