diff -r 9ed07a96349d -r 265e5997580e hedgewars/uLandPainted.pas --- a/hedgewars/uLandPainted.pas Fri Sep 27 21:52:21 2013 -0400 +++ b/hedgewars/uLandPainted.pas Mon Sep 30 00:20:58 2013 +0400 @@ -27,7 +27,7 @@ procedure freeModule; implementation -uses uLandGraphics, uConsts, uVariables, uUtils, SDLh, uCommands, uDebug; +uses uLandGraphics, uConsts, uVariables, uUtils, SDLh, uCommands, uDebug, uScript; type PointRec = packed record X, Y: SmallInt; @@ -88,7 +88,11 @@ radius:= 0; pe:= pointsListHead; - TryDo((pe = nil) or (pe^.point.flags and $80 <> 0), 'Corrupted draw data', true); + while (pe <> nil) and (pe^.point.flags and $80 = 0) do + begin + ScriptCall('onSpecialPoint', pe^.point.X, pe^.point.Y, pe^.point.flags); + pe:= pe^.next; + end; while(pe <> nil) do begin @@ -110,7 +114,7 @@ end; prevPoint:= pe^.point; - pe:= pe^.next; + pe:= pe^.next; end; end;