Originally Posted by
Youbaron
Yeah, keeps on taking out the ess and banking it =/
The solution is simple, though I'm not sure if it is a leech countermeasure. I will post it with fre's permission.
To fre:
You have an "anti-ban" procedure, but you don't call it anywhere. It would also be wise to make use of the "FindNormalRandoms" function.
Might I suggest a few changes to your "ListenMusic" procedure?
Maybe check the player's energy before resting, and randomly get up after regenerating so much energy. And also add a fail-safe for when the script doesn't click on the musician, and your waiting while while slowly regenerating energy.
I have yet to test this code, but I plan to later today. You may have to play with some of the numbers.
Code:
Procedure ListenMusic;
var
ColorsTPA : TPointArray;
MusicianTPA : T2DPointArray;
i, x, y, attempts : Integer;
s: String;
begin
if (GetMMLevels('run', s) < 60) then // Continue if energy is less than 50
begin
repeat
attempts:=attempts+1;
FindColorsSpiralTolerance(MSX2/2, MSY2/2, ColorsTPA, 8168378, MSX1, MSY1, MSX2, MSY2, 30);
MusicianTPA := SplitTPA(ColorsTPA,30);
for i := 0 to high(MusicianTPA) do
begin
if GetArrayLength(MusicianTPA[i]) > 10 then
begin
MiddleTPAEx(MusicianTPA[i], x, y);
MMouse(x-5, y-5, 5, 5);
wait(500+random(200));
if IsUpText('isten') or IsUpText('usic') then
ClickMouse2(false);
ChooseOption('isten');
end;
end;
until(DidClick(true,500) Or (attempts=5)) // Repeat until red click or tried 5 times
if(attempts=5) then exit; // Walk to the bank if the musician was never clicked
end;
repeat
wait(200); // Why check more than 5 times a second?
until(GetMMLevels('run', s) > 60) // Move on when energy is at least 52
wait(200 + random(700)); // randomness
end;