slushpuppy
2012-12-08 11:05:52
why does this throw a mismatch error? http://pastebin.com/My4Cxw87
line 17
line 17
2012-12-08 11:05:52
2012-12-08 11:26:51
type
RW_CheckPoint = Record
till: Boolean;
color,tolerance : Integer;
end;
function RW_noop : Boolean;
begin
Result := false;
end;
function RW_Point(c,t : Integer; WalkUntil : function : Boolean) : RW_CheckPoint;
begin
with Result do
begin
color := c;
t := tolerance;
till := WalkUntil();
end;
end;
2012-12-08 22:31:21
type
RW_TBoolFunc = function : Boolean;
RW_TPoint = Record
dir : extended;
till : RW_TBoolFunc;
color,tolerance : Integer;
end;
var
RW_Accuracy : Integer;
function RW_noop : Boolean;
begin
Result := false;
end;
procedure RW_setAccuracy(lvl : Integer);
begin
RW_Accuracy := lvl;
end;
procedure RW_setup;
begin
RW_setAccuracy(5);
end;
function RW_Point(direction : char;c,t : Integer; WalkUntil : RW_TBoolFunc) : RW_TPoint;
begin
with Result do
begin
color := c;
t := tolerance;
till := WalkUntil;
dir := variantToDirection(direction);
end;
end;
2012-12-08 22:42:23