DEADSOFTWARE

render: draw flag animation using TAnimationState
[d2df-sdl.git] / src / game / g_map.pas
index f53fd1500ec723ef7bdcfca6c93aa7c37dbfc24b..2ca5bb67c604fc8f1f03c53aa87575eb260524e2 100644 (file)
@@ -52,7 +52,6 @@ type
     State:       Byte;
     Count:       Integer;
     CaptureTime: LongWord;
-    Animation:   TAnimation;
     Direction:   TDirection;
   end;
 
@@ -1078,7 +1077,6 @@ end;
 procedure CreateArea(Area: TDynRecord);
 var
   a: Integer;
-  id: DWORD = 0;
 begin
   case Area.AreaType of
     AREA_DMPOINT, AREA_PLAYERPOINT1, AREA_PLAYERPOINT2,
@@ -1118,14 +1116,7 @@ begin
 
       with gFlags[a] do
       begin
-        case a of
-          FLAG_RED: g_Frames_Get(id, 'FRAMES_FLAG_RED');
-          FLAG_BLUE: g_Frames_Get(id, 'FRAMES_FLAG_BLUE');
-        end;
-
-        Animation := TAnimation.Create(id, True, 8);
         Obj.Rect := FLAGRECT;
-
         g_Map_ResetFlag(a);
       end;
     end;
@@ -2204,8 +2195,6 @@ begin
       begin
         with gFlags[a] do
         begin
-          if gFlags[a].Animation <> nil then gFlags[a].Animation.Update();
-
           m := g_Obj_Move(@Obj, True, True);
 
           if gTime mod (GAME_TICK*2) <> 0 then Continue;