Hey guys I'm working on my cooking script and everything seems to be going fine except one thing.
Using the range seems to be very random-prone, so I was trying to use FindNormalRandoms in the loop where it waits for the stuff to be cooked to try to catch out the randoms, but it doesnt want to work. It also doesnt find the old man when walking to the range.
Can you guys check this code?
SCAR Code:
procedure Cook;
var
c,b: Integer;
begin
FindNormalRandoms;
if ClickInvBmp(UncookedBmp,70,'') then
begin
if FindObj(x, y, 'ange', RangeColor, 30) then
begin
Mouse(x,y,5,5,True);
Flag;
Wait(1500+random(500));
FindNormalRandoms;
Mouse(258,430,15,15,False);//Just selecting the pie when it appears.
Wait(1500+random(100));
if ClickOption('5',3) then
begin
wait(15000+random(3000));
repeat
Talk;
AntiBan;
if FindNormalRandoms then //This Part just wont work!
begin
Cook;
Break;
end;
wait(100);
until (AllCooked);
end;
end;
c:=InvCheck('cooked');
b:=InvCheck('burnt');
Cooked:=Cooked+c;
ReportVars[0] := ReportVars[0] + c;
Burnt:= Burnt+b;
ReportVars[1] := ReportVars[1] + b;
ProgressReport;
//Just emptying the pie dishes
repeat
ClickInvBmp(BurntBmp,70,'mpty');
wait(300+random(200));
until InvCheck('burnt')=0;
repeat
ClickInvBmp(CookedBmp,70,'');
Wait(300+random(200));
until InvCheck('cooked')=0;
repeat
ClickInvBmp(HalfPieBmp,70,'');
Wait(300+random(200));
until InvCheck('halfpie')=0;
end;
end;
Thats the cooking procedure.
InvCheck just checks how many of the item are in the inventory
ClickInvBmp does what it suggests
If you could find the problem quickly I would be very grateful and give you credit because I want to meet the deadline I set which is today.
Thanks in advance