merge
authormikade
Mon, 15 Aug 2011 19:42:39 +0200
changeset 5575 41ee1c71deb3
parent 5571 434ec40070e0 (current diff)
parent 5574 3d7438991ed8 (diff)
child 5576 bf30c60786a5
child 5577 272c82f82cee
merge
--- a/gameServer/HWProtoLobbyState.hs	Mon Aug 15 17:29:54 2011 +0200
+++ b/gameServer/HWProtoLobbyState.hs	Mon Aug 15 19:42:39 2011 +0200
@@ -132,9 +132,10 @@
 handleCmd_lobby ["FOLLOW", asknick] = do
     (_, rnc) <- ask
     ci <- clientByNick asknick
+    cl <- thisClient
     let ri = clientRoom rnc $ fromJust ci
     let clRoom = room rnc ri
-    if isNothing ci || ri == lobbyId then
+    if isNothing ci || ri == lobbyId || clientProto cl /= roomProto clRoom then
         return []
         else
         handleCmd_lobby ["JOIN_ROOM", name clRoom]
--- a/hedgewars/uCollisions.pas	Mon Aug 15 17:29:54 2011 +0200
+++ b/hedgewars/uCollisions.pas	Mon Aug 15 19:42:39 2011 +0200
@@ -84,8 +84,9 @@
 if (Count > (MAXRECTSINDEX-20)) then
     begin
     t:= GearsList;
-    while (t <> nil) and (t^.Kind <> gtMine) do t:= t^.NextGear;
-    if (t <> nil) and (t^.Kind = gtMine) then DeleteGear(t)
+    while (t <> nil) and (t^.Kind <> gtMine) do 
+        t:= t^.NextGear;
+    if (t <> nil) then DeleteGear(t)
     end;
 end;
 
--- a/hedgewars/uVisualGears.pas	Mon Aug 15 17:29:54 2011 +0200
+++ b/hedgewars/uVisualGears.pas	Mon Aug 15 19:42:39 2011 +0200
@@ -280,7 +280,8 @@
                 Frame:= 1
                 end;
   vgtHealthTag: begin
-                gear^.Timer:= 1500;
+                Frame:= 0;
+                Timer:= 1500;
                 //gear^.Z:= 2002;
                 end;
   vgtSmokeTrace,
@@ -479,7 +480,7 @@
             vgtSmallDamageTag: DrawCentered(round(Gear^.X) + WorldDx, round(Gear^.Y) + WorldDy, Gear^.Tex);
             vgtHealthTag: if Gear^.Tex <> nil then 
                             begin
-                            if Gear^.State = 0 then 
+                            if Gear^.Frame = 0 then 
                                 DrawCentered(round(Gear^.X) + WorldDx, round(Gear^.Y) + WorldDy, Gear^.Tex)
                             else
                                 begin