From efad5c8ee1b2bcdd58b2b7a4a990daa5cf793a59 Mon Sep 17 00:00:00 2001 From: DeaDDooMER Date: Sun, 21 Jul 2019 16:51:21 +0300 Subject: [PATCH] fix map test on linux --- src/editor/f_main.pas | 32 +++++++++++++++++--------------- 1 file changed, 17 insertions(+), 15 deletions(-) diff --git a/src/editor/f_main.pas b/src/editor/f_main.pas index b980fb5..99ddcd9 100644 --- a/src/editor/f_main.pas +++ b/src/editor/f_main.pas @@ -6628,7 +6628,7 @@ end; procedure TMainForm.miTestMapClick(Sender: TObject); var - cmd, mapWAD, mapToRun, tempWAD: String; + mapWAD, mapToRun, tempWAD: String; opt: LongWord; time: Integer; proc: TProcessUTF8; @@ -6669,23 +6669,25 @@ begin if TestOptionsMonstersDM then opt := opt + 16; -// Составляем командную строку: - cmd := '-map "' + mapToRun + '"'; - cmd := cmd + ' -testmap "' + tempWAD + '"'; - cmd := cmd + ' -gm ' + TestGameMode; - cmd := cmd + ' -limt ' + TestLimTime; - cmd := cmd + ' -lims ' + TestLimScore; - cmd := cmd + ' -opt ' + IntToStr(opt); - - if TestMapOnce then - cmd := cmd + ' --close'; - - cmd := cmd + ' --debug'; - // Запускаем: proc := TProcessUTF8.Create(nil); proc.Executable := TestD2dExe; - proc.Parameters.Add(cmd); + proc.Parameters.Add('-map'); + proc.Parameters.Add(mapToRun); + proc.Parameters.Add('-testmap'); + proc.Parameters.Add(tempWAD); + proc.Parameters.Add('-gm'); + proc.Parameters.Add(TestGameMode); + proc.Parameters.Add('-limt'); + proc.Parameters.Add(TestLimTime); + proc.Parameters.Add('-lims'); + proc.Parameters.Add(TestLimScore); + proc.Parameters.Add('-opt'); + proc.Parameters.Add(IntToStr(opt)); + proc.Parameters.Add('--debug'); + if TestMapOnce then + proc.Parameters.Add('--close'); + res := True; try proc.Execute(); -- 2.29.2