hedgewars/uGearsUtils.pas
changeset 10634 35d059bd0932
parent 10558 b574f04c9685
child 10653 ae9ad7735690
--- a/hedgewars/uGearsUtils.pas	Sun Dec 07 14:36:28 2014 -0500
+++ b/hedgewars/uGearsUtils.pas	Mon Dec 08 09:35:14 2014 -0500
@@ -700,7 +700,7 @@
         with CurrentHedgehog^ do
             begin
             inc(Team^.stats.AIKills);
-            FreeTexture(Team^.AIKillsTex);
+            FreeAndNilTexture(Team^.AIKillsTex);
             Team^.AIKillsTex := RenderStringTex(ansistring(inttostr(Team^.stats.AIKills)), Team^.Clan^.Color, fnt16);
             end;
     tempTeam := gear^.Hedgehog^.Team;