DEADSOFTWARE

removing dfwad writing abilities; removed "--testdelete" argument
[d2df-sdl.git] / src / game / g_game.pas
index 70dba84c6abbe6fe6663cf7058cb9ef4e8b0937d..0862e74a18977c7422c08df6058b8a58a4d85f86 100644 (file)
@@ -1058,7 +1058,7 @@ begin
   g_Game_SetLoadingText(_lc[I_LOAD_MUSIC], 0, False);
   g_Sound_CreateWADEx('MUSIC_INTERMUS', GameWAD+':MUSIC\INTERMUS', True);
   g_Sound_CreateWADEx('MUSIC_MENU', GameWAD+':MUSIC\MENU', True);
-  g_Sound_CreateWADEx('MUSIC_ROUNDMUS', GameWAD+':MUSIC\ROUNDMUS');
+  g_Sound_CreateWADEx('MUSIC_ROUNDMUS', GameWAD+':MUSIC\ROUNDMUS', True);
   g_Sound_CreateWADEx('MUSIC_STDENDMUS', GameWAD+':MUSIC\ENDMUS', True);
 
   g_Game_SetLoadingText(_lc[I_LOAD_MENUS], 0, False);
@@ -1230,7 +1230,7 @@ begin
         if (not g_Game_IsClient) and
         (
           (
-            (e_KeyPressed(IK_RETURN) or e_KeyPressed(IK_SPACE))
+            (e_KeyPressed(IK_RETURN) or e_KeyPressed(IK_KPRETURN) or e_KeyPressed(IK_SPACE))
             and (not gJustChatted) and (not gConsoleShow) and (not gChatShow)
             and (g_ActiveWindow = nil)
           )
@@ -4045,11 +4045,14 @@ end;
 
 procedure g_Game_DeleteTestMap();
 var
-  WAD: TWADEditor_1;
+  a: Integer;
   MapName: Char16;
-  MapList: SArray;
-  a, time: Integer;
   WadName: string;
+{
+  WAD: TWADEditor_1;
+  MapList: SArray;
+  time: Integer;
+}
 begin
   a := Pos('.wad:\', gMapToDelete);
   if a = 0 then
@@ -4062,6 +4065,7 @@ begin
   MapName := '';
   CopyMemory(@MapName[0], @gMapToDelete[1], Min(16, Length(gMapToDelete)));
 
+{
 // Èìÿ êàðòû íå ñòàíäàðòíîå òåñòîâîå:
   if MapName <> TEST_MAP_NAME then
     Exit;
@@ -4095,7 +4099,8 @@ begin
     WAD.Free();
     g_SetFileTime(WadName, time);
   end else
-    DeleteFile(WadName);
+}
+  if gTempDelete then DeleteFile(WadName);
 end;
 
 procedure GameCVars(P: SArray);
@@ -6291,7 +6296,11 @@ begin
   // Delete test map after play:
     s := Find_Param_Value(pars, '--testdelete');
     if (s <> '') then
+    begin
       gMapToDelete := MapsDir + map;
+      e_WriteLog('"--testdelete" argument doesn''t supported anymore!', MSG_FATALERROR);
+      Halt(1);
+    end;
 
   // Delete temporary WAD after play:
     s := Find_Param_Value(pars, '--tempdelete');