diff --git a/src/editor/f_main.pas b/src/editor/f_main.pas
index 00802bbdd83bed88d058252f8107dc09979495bd..1d1d2ce5da316808b4db68c1e3fb168ed1ac12f8 100644 (file)
--- a/src/editor/f_main.pas
+++ b/src/editor/f_main.pas
if vleObjectProperty.Values[_lc[I_PROP_TR_MUSIC_ACT]] = _lc[I_PROP_TR_MUSIC_ON] then
Data.MusicAction := 1
else
- Data.MusicAction := 2;
+ Data.MusicAction := 0;
end;
TRIGGER_PUSH:
procedure TMainForm.miTestMapClick(Sender: TObject);
var
- newWAD, oldWAD, tempMap: String;
+ newWAD, oldWAD, tempMap, ext: String;
args: SSArray;
opt: LongWord;
time, i: Integer;
// Сохраняем временную карту:
time := 0;
repeat
- newWAD := ExtractFilePath(TestD2dExe) + Format('maps/temp%.4d.wad', [time]);
+ newWAD := ExtractFilePath(TestD2dExe) + Format('maps/temp%.4d', [time]);
Inc(time);
until not FileExists(newWAD);
if OpenedMap <> '' then
begin
oldWad := g_ExtractWadName(OpenedMap);
+ newWad := newWad + ExtractFileExt(oldWad);
if CopyFile(oldWad, newWad) = false then
e_WriteLog('MapTest: unable to copy [' + oldWad + '] to [' + newWad + ']', MSG_WARNING)
+ end
+ else
+ begin
+ newWad := newWad + '.wad'
end;
tempMap := newWAD + ':\' + TEST_MAP_NAME;
SaveMap(tempMap);