The reason you were getting the error before Agent posted is because you aren't giving it any parameters.
Instead of this:
SCAR Code:
procedure MainLoop;
begin
repeat
withdrawclay;
useitems; // <-----This line gets the error
bankclay;
until(LodesDone = LodesToDo);
end;
Do this:
SCAR Code:
procedure MainLoop;
begin
repeat
withdrawclay;
useitems(1, 15); // <-----This line gets the error
bankclay;
until(LodesDone = LodesToDo);
end;
Also, if your looking to use the first fourteen items with the last fourteen items, you can do something like this:
SCAR Code:
procedure MainLoop;
Var
I : Integer;
begin
repeat
withdrawclay;
For I:=0 To 14 Do
Begin
useitems(I, I+14); // <-----This line gets the error
End;
bankclay;
until(LodesDone = LodesToDo);
end;