QAZ
2012-06-06 18:06:33
what does this mean? thanks
2012-06-06 18:06:33
2012-06-06 18:08:23
2012-06-06 18:11:53
From: YoHoJo
You keep making help threads but don't provide code.
We will gladly help you with any coding, but it helps us A LOT when you show us the code too.
It basically means you have given a procedure/function too many/too few parameters.
Ex:
Wait(100); is perfect
but
Wait(100, '5', 4, 3); makes no sense, wait only needs one parameter, the wait time.
procedure Cook;
var x, y, i, kill, kill2, Antiban, When:Integer;
Tp:TPoint;
InventSpotsX1, InventSpotsY1, InventSpotsX2, InventSpotsY2:TIntegerArray;
begin
FindRandoms;
DoingATM := 'Finding Range';
PrintProggy;
if NextAcc then
Exit;
MouseSpeed := 19 + random(2);
while isMoving do wait(200+random(200));
if not(GetRangePos(Tp)) then
begin
writeln('GetRangePos returned false');
NextPlayer(False);
NextAcc := True;
Exit;
end;
x := Tp.x;
y := Tp.y;
mouse(x, y, 4, 4, True);
MouseSpeed := 11 + random(2);
MMouse(351 + random(151), 289 + random(43), 3, 3);
DoingATM := 'Finding Range';
PrintProggy;
repeat
inc(kill);
wait(150 + random(100));
until (kill=20) or (FindDTM(Raw_Fish, x, y, 218, 393, 281, 434))
if (kill>19) then
begin
MouseSpeed := 12 + random(2);
invmouse(1,1);
wait(300 + random(200));
MouseSpeed := 19 + random(2);
if not(GetRangePos(Tp)) then
begin
writeln('Range wasnt found..');
NextPlayer(False);
NextAcc := True;
Exit;
end;
x := Tp.x;
y := Tp.y;
mouse(x, y, 4, 4, True);
MouseSpeed := 11 + random(2);
end;
while isMoving do wait(200+random(200));
if FindDTM(Raw_Fish, x, y, 218, 393, 281, 434) then
begin
x := x + random(10);
y := y + random(10);
mouse(x, y, 0, -3, true);
wait(800 + random(450));
kill := 0;
end;
SetArrayLength(InventSpotsX1, 28);
SetArrayLength(InventSpotsY1, 28);
SetArrayLength(InventSpotsX2, 28);
SetArrayLength(InventSpotsY2, 28);
InventSpotsX1 :=
[560, 601, 642, 683,
560, 601, 642, 683,
560, 601, 642, 683,
560, 601, 642, 683,
560, 601, 642, 683,
560, 601, 642, 683,
560, 601, 642, 683];
InventSpotsX2 :=
[601, 642, 683, 724,
601, 642, 683, 724,
601, 642, 683, 724,
601, 642, 683, 724,
601, 642, 683, 724,
601, 642, 683, 724,
601, 642, 683, 724];
InventSpotsY1 :=
[210, 210, 210, 210,
247, 247, 247, 247,
284, 284, 284, 284,
321, 321, 321, 321,
357, 357, 357, 357,
393, 393, 393, 393,
429, 429, 429, 429];
InventSpotsY2 :=
[247, 247, 247, 247,
284, 284, 284, 284,
321, 321, 321, 321,
357, 357, 357, 357,
393, 393, 393, 393,
429, 429, 429, 429,
465, 465, 465, 465];
DoingATM := 'Cooking';
AddToStats := True;
AntiBan := random(2);
if AntiBan = 1 then
begin
When := random(23);
end else
When := -1;
for i := 0 to 27 do
begin
repeat
Wait(random(398));
inc(Kill2);
until (not(FindDTM(Raw_Fish, x, y, InventSpotsX1[I], InventSpotsY1[I],
InventSpotsX2[I], InventSpotsY2[I])) or (Kill2 = 30))
FindRandoms;
if Kill2 = 30 then
break;
if (not(FindDTM(Cooked_Fish, x, y, InventSpotsX1[I], InventSpotsY1[I],
InventSpotsX2[I], InventSpotsY2[I])) and ExistsItem(I + 1) and
not(FindDTM(Raw_Fish, x, y, InventSpotsX1[I], InventSpotsY1[I],
InventSpotsX2[I], InventSpotsY2[I])) ) then { and not(FindDTM(Raw_Fish,
x, y, InventSpotsX1[I + 1], InventSpotsY1[I + 1], InventSpotsX2[I + 1],
InventSpotsY2[I + 1])) }
begin
IsFishBurned := True;
inc(FishBurned);
end else
inc(FishCooked);
if not(ExistsItem(I + 1)) then
begin
ToBank;
writeln('Out of fish.');
NextPlayer(False);
NextAcc := True;
OutOfFish := True;
Exit;
end;
PrintProggy;
if i = 26 then
MMouse(565 + random(111), 96 + random(68), 3, 3);
//antiban
if i = When then
begin
DoingATM := 'AntiBan';
PrintProggy;
if GameTab(tab_Stats) then
begin
HoverSkill(Skill_Cooking, False);
wait(500 + random(300));
GameTab(tab_Inv);
wait(200 + random(250));
end else
FindRandoms;
DoingATM := 'Cooking';
end;
//end of antiban
Kill2 := 0;
end;
AddToStats := False;
FindRandoms;
if NextAcc then
Exit;
MouseSpeed := 13 + random(2);
end;
2012-06-06 18:16:40
2012-06-06 18:22:28
From: YoHoJo
Might be best to make new script from scratch rather than trying to update an old one and understand someone elses code if you;re not too super at coding.
Which line is the error on.
2012-06-06 18:29:01
Mouse(X, Y, 5, 5, False);
WaitOption('dd a', 250);2012-06-06 18:30:21
From: YoHoJo
Mouse(X, Y, 5, 5, False);
WaitOption('dd a', 250);
^That will do it.
X and Y of course being the coordinates of the food.
2012-06-06 18:44:12
2012-06-06 18:49:54
2012-06-06 18:52:27
From: YoHoJo
Yeah.
Reviving an old/dead script is only easy if you are already good at coding, and even if you are, it's sometimes not very easy/intuitive to follow another person's code.
It would honestly be best if you just started reading beginner tutorials, took the time to learn to code spending a few hours each day, and then made your own.
Besides being old and not compiling, the script may have tons of other problems like outdated colors, bitmaps, dtms, etc.