mirror of
https://github.com/alliedmodders/amxmodx.git
synced 2024-12-25 06:15:37 +03:00
component update, fixed metamod plugins.ini bug once and for all
This commit is contained in:
parent
73386b12c5
commit
947cb5f79d
Binary file not shown.
@ -3,7 +3,7 @@ unit UnitInstall;
|
|||||||
interface
|
interface
|
||||||
|
|
||||||
uses SysUtils, Classes, Windows, Graphics, Forms, ShellAPI, Controls, Messages,
|
uses SysUtils, Classes, Windows, Graphics, Forms, ShellAPI, Controls, Messages,
|
||||||
TlHelp32, IdFTPCommon, ComCtrls, JclFileUtils;
|
TlHelp32, IdFTPCommon, ComCtrls, JclFileUtils, Dialogs;
|
||||||
|
|
||||||
type TMod = (modNone, modCS, modDoD, modTFC, modNS, modTS, modESF);
|
type TMod = (modNone, modCS, modDoD, modTFC, modNS, modTS, modESF);
|
||||||
type TOS = (osWindows, osLinux32, osLinux64);
|
type TOS = (osWindows, osLinux32, osLinux64);
|
||||||
@ -500,15 +500,15 @@ begin
|
|||||||
if (FileExists(ePath + 'addons\metamod\plugins.ini')) then begin
|
if (FileExists(ePath + 'addons\metamod\plugins.ini')) then begin
|
||||||
eStr.LoadFromFile(ePath + 'addons\metamod\plugins.ini');
|
eStr.LoadFromFile(ePath + 'addons\metamod\plugins.ini');
|
||||||
if OS = osWindows then begin
|
if OS = osWindows then begin
|
||||||
if (Pos(eStr.Text, 'addons\amxmodx\dlls\amxmodx_mm.dll') <> 0) then
|
if (Pos('addons\amxmodx\dlls\amxmodx_mm.dll', eStr.Text) <> 0) then
|
||||||
UpdatePluginsIni := False;
|
UpdatePluginsIni := False;
|
||||||
end
|
end
|
||||||
else if OS = osLinux32 then begin
|
else if OS = osLinux32 then begin
|
||||||
if (Pos(eStr.Text, 'addons/amxmodx/dlls/amxmodx_mm_i386.so') <> 0) then
|
if (Pos('addons/amxmodx/dlls/amxmodx_mm_i386.so', eStr.Text) <> 0) then
|
||||||
UpdatePluginsIni := False;
|
UpdatePluginsIni := False;
|
||||||
end
|
end
|
||||||
else begin
|
else begin
|
||||||
if (Pos(eStr.Text, 'addons/amxmodx/dlls/amxmodx_mm_amd64.so') <> 0) then
|
if (Pos('addons/amxmodx/dlls/amxmodx_mm_amd64.so', eStr.Text) <> 0) then
|
||||||
UpdatePluginsIni := False;
|
UpdatePluginsIni := False;
|
||||||
end;
|
end;
|
||||||
end
|
end
|
||||||
@ -804,8 +804,9 @@ begin
|
|||||||
frmMain.ggeItem.Progress := 0;
|
frmMain.ggeItem.Progress := 0;
|
||||||
end;
|
end;
|
||||||
AddStatus('', clBlack, False);
|
AddStatus('', clBlack, False);
|
||||||
AddStatus('Cleaning installation...', clBlack, False);
|
AddStatus('Cleaning up installation...', clBlack, False);
|
||||||
DelTree(ExtractFilePath(ParamStr(0)) + 'temp');
|
if (DirectoryExists(ExtractFilePath(ParamStr(0)) + 'temp')) then
|
||||||
|
DelTree(ExtractFilePath(ParamStr(0)) + 'temp');
|
||||||
AddDone;
|
AddDone;
|
||||||
|
|
||||||
frmMain.ggeAll.Progress := frmMain.ggeAll.MaxValue;
|
frmMain.ggeAll.Progress := frmMain.ggeAll.MaxValue;
|
||||||
|
@ -6433,6 +6433,8 @@ object frmMain: TfrmMain
|
|||||||
Width = 509
|
Width = 509
|
||||||
Height = 24
|
Height = 24
|
||||||
AdvColorBorder = 0
|
AdvColorBorder = 0
|
||||||
|
Color = clBtnFace
|
||||||
|
ColorBorder = 8623776
|
||||||
Progress = 0
|
Progress = 0
|
||||||
Font.Charset = DEFAULT_CHARSET
|
Font.Charset = DEFAULT_CHARSET
|
||||||
Font.Color = clWindowText
|
Font.Color = clWindowText
|
||||||
@ -6455,6 +6457,8 @@ object frmMain: TfrmMain
|
|||||||
Width = 509
|
Width = 509
|
||||||
Height = 24
|
Height = 24
|
||||||
AdvColorBorder = 0
|
AdvColorBorder = 0
|
||||||
|
Color = clBtnFace
|
||||||
|
ColorBorder = 8623776
|
||||||
Progress = 0
|
Progress = 0
|
||||||
Font.Charset = DEFAULT_CHARSET
|
Font.Charset = DEFAULT_CHARSET
|
||||||
Font.Color = clWindowText
|
Font.Color = clWindowText
|
||||||
|
@ -763,6 +763,7 @@ begin
|
|||||||
rtfDetails.Clear;
|
rtfDetails.Clear;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
// delete files, then directories
|
||||||
if (DirectoryExists(ExtractFilePath(ParamStr(0)) + 'temp')) then
|
if (DirectoryExists(ExtractFilePath(ParamStr(0)) + 'temp')) then
|
||||||
DelTree(ExtractFilePath(ParamStr(0)) + 'temp');
|
DelTree(ExtractFilePath(ParamStr(0)) + 'temp');
|
||||||
end;
|
end;
|
||||||
@ -874,9 +875,14 @@ begin
|
|||||||
if IdFTP.Connected then
|
if IdFTP.Connected then
|
||||||
IdFTP.Quit;
|
IdFTP.Quit;
|
||||||
end
|
end
|
||||||
else
|
else begin
|
||||||
Action := caNone;
|
Action := caNone;
|
||||||
|
exit;
|
||||||
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
if (DirectoryExists(ExtractFilePath(ParamStr(0)) + 'temp')) then
|
||||||
|
DelTree(ExtractFilePath(ParamStr(0)) + 'temp');
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TfrmMain.ExceptionHandler(Sender: TObject; E: Exception);
|
procedure TfrmMain.ExceptionHandler(Sender: TObject; E: Exception);
|
||||||
|
Loading…
Reference in New Issue
Block a user