DEADSOFTWARE

don't hit monsters on the client when it's warmup time
[d2df-sdl.git] / src / game / g_weapons.pas
index 21b206127a34928f44cb9c90de0fd5adcbfc570b..498487da73d4acd8862ebf74841bb33479940ad3 100644 (file)
@@ -2,8 +2,7 @@
  *
  * This program is free software: you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
+ * the Free Software Foundation, version 3 of the License ONLY.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -462,12 +461,12 @@ begin
     if (t <> HIT_FLAME) or (m.FFireTime = 0) or (vx <> 0) or (vy <> 0) then
       Result := m.Damage(d, vx, vy, SpawnerUID, t)
     else
-      Result := True;
+      Result := (gLMSRespawn <> LMS_RESPAWN_WARMUP); // don't hit monsters when it's warmup time
     if t = HIT_FLAME then
       m.CatchFire(SpawnerUID);
   end
   else
-    Result := True;
+    Result := (gLMSRespawn <> LMS_RESPAWN_WARMUP); // don't hit monsters when it's warmup time
 end;
 
 
@@ -2346,7 +2345,7 @@ begin
                 Stopped := MOVE_HITCEIL;
             end;
 
-            a := IfThen(Stopped = 0, 3, 1);
+            a := IfThen(Stopped = 0, 10, 1);
           // Åñëè â êîãî-òî ïîïàëè
             if g_Weapon_Hit(@Obj, a, SpawnerUID, HIT_FLAME, False) <> 0 then
             begin