hedgewars/uLandOutline.pas
changeset 10560 9f09196d92a6
parent 10510 9329dab04490
child 11532 bf86c6cb9341
equal deleted inserted replaced
10556:c4ca0fc00c3b 10560:9f09196d92a6
   251 
   251 
   252 function CheckSelfIntersect(var pa: TPixAr; ind: Longword): boolean;
   252 function CheckSelfIntersect(var pa: TPixAr; ind: Longword): boolean;
   253 var i: Longword;
   253 var i: Longword;
   254 begin
   254 begin
   255     CheckSelfIntersect:= false;
   255     CheckSelfIntersect:= false;
   256     if (ind <= 0) or (ind >= Pred(pa.Count)) then
   256     if (ind <= 0) or (LongInt(ind) >= Pred(pa.Count)) then
   257         exit;
   257         exit;
   258 
   258 
   259     CheckSelfIntersect:= true;
   259     CheckSelfIntersect:= true;
   260     for i:= 1 to pa.Count - 3 do
   260     for i:= 1 to pa.Count - 3 do
   261         if (i <= ind - 1) or (i >= ind + 2) then
   261         if (i <= ind - 1) or (i >= ind + 2) then