Trying to make a simple auto caster on demon in wizzy tower but it will hover over the demon, move to different parts of it, with the spell queued up but it won't cast it, and it will sometimes click the home teleport and keep doing it and eventually i end up in lumby. Here's what I've tried last
Simba Code:
program AutoBlast;
{$DEFINE SMART8}
{$I SRL/SRL.simba}
{$I P07Include.simba}
Procedure AntiBan;
begin
if(not(P07_LoggedIn)) then
Exit;
Case (Random(10)) Of
1:
begin
P07_HoverSkill('random', RandomRange(1000, 2000));
Wait(2500 + Random(500));
end;
3:
begin
P07_MakeCameraAngleHigh();
Wait(250 + Random(250));
end;
5:
begin
P07_MakeCameraAngleLow();
Wait(350 + Random(300));
end;
end;
end;
Procedure P07_DeclarePlayers;
begin
P07_PlayerName := '';
P07_PlayerPass := '';
end;
Procedure CastMSpell;
var
x, y: Integer;
begin
repeat
begin
FindNormalRandoms();
if(P07_CastSpell(2)) then
begin
if(FindObjCustom(x, y, ['Lesser'], [530767, 532062], 5)) then
begin
x := x + Random(2);
y := y + Random(2);
MMouse(x, y, 1, 1);
ClickMouse2(mouse_left);
Wait(2000 + Random(350));
end;
end;
end;
until(false)
end;
begin
P07_DeclarePlayers;
SetUpSRL;
SetupP07Include;
P07_LoginPlayer;
Wait(250);
CastMSpell;
end.
[EDIT] Fixed. Forgot P07 Include had its own FindObjCustom so I didn't add P07_FindObjCustom, works fine now. Hehe. This is for anyone else's benefit now. Thanks.