DEADSOFTWARE

Player: Always reset special vars on respawn
[d2df-sdl.git] / src / game / g_player.pas
index 103d2f59bf949f86863e759432deea2dbbf584b9..8c64fd0423ce66f9c7717fd1353abef54bd233a9 100644 (file)
@@ -588,10 +588,15 @@ procedure g_Bot_RemoveAll();
 implementation
 
 uses
+{$IFDEF USE_NANOGL}
+  nanoGL,
+{$ELSE}
+  GL,
+{$ENDIF}
   e_log, g_map, g_items, g_console, g_gfx, Math,
   g_options, g_triggers, g_menu, g_game, g_grid,
   wadreader, g_main, g_monsters, CONFIG, g_language,
-  g_net, g_netmsg, g_window, GL, g_holmes,
+  g_net, g_netmsg, g_window, g_holmes,
   utils, xstreams;
 
 const PLR_SAVE_VERSION = 0;
@@ -4337,6 +4342,12 @@ var
   Anim: TAnimation;
   ID: DWORD;
 begin
+  FIncCam := 0;
+  FBFGFireCounter := -1;
+  FShellTimer := -1;
+  FPain := 0;
+  FLastHit := 0;
+
   if not g_Game_IsServer then
     Exit;
   if FDummy then
@@ -4441,12 +4452,6 @@ begin
   else
     FAngle := 0;
 
-  FIncCam := 0;
-  FBFGFireCounter := -1;
-  FShellTimer := -1;
-  FPain := 0;
-  FLastHit := 0;
-
   SetAction(A_STAND, True);
   FModel.Direction := FDirection;