my bot is right clicking all monsters in pest control before selecting attack from the list
any ideas on how to fix this?
Printable View
my bot is right clicking all monsters in pest control before selecting attack from the list
any ideas on how to fix this?
Umm, post the code ;)
-Boom
umm i'm not sure what part would be useful, would it be to do with the script because its only started happening since the update
Oh darns, your script is broken and there's not a free version available anymore.
Your choices are either fix it yourself or stop using it.
yeah i know, i've managed to get it working except for this constant right clicking
i'm happy to learn if anyone wishes to give me a push in the right direction. I managed to get it working with SRL5 but I got stuck on this because im new to simba
i've never asked for anyone to do it for me, i said from the start any ideas on how i could fix it.
i've currently managed to get it to stop right clicking but i know this would only be temporary by changing the MOUSE_RIGHT where it attacks the monsters to MOUSE_LEFT
anyone able to help me correct this?Quote:
begin
GetMousePos(StartX, StartY);
GMMouse(x, y, rx, ry);
GetMousePos(TargetX, TargetY);
if left then Button := MOUSE_LEFT
else Button := MOUSE_LEFT;
//else Button := MOUSE_RIGHT;
HoldMouse(TargetX, TargetY, Button);
Wait(25+Round(Gaussian(70, 2.3, True)));
if (Random(15) = 0) then
begin
just use Mouse(x, y, rx, ry, True) instead of hold mouse and change button to a boolean
post it ill help , that kid is being an asshole
I'm not being an asshole, I'm simply stating the fact that if he wishes to use a script that was removed due to leaching, he should have to fix it himself.
Helping him would be like telling him how to add summoning to Flight's Nat Crafter.... and in my personal opinion it would be leaking Member's scripts.
I was not talking about you PATDUFFY!
Anyone who posts or shares the script that's now SRL Members will be considered leaking and will be banned from the forums for a very long time.
Learn to fix it yourself, or don't use it.
Find the procedure that tells the bot to click on the monster, it should look something like this:
Change that one "false" to "true" and it will only right-click when necessary.Code:Mouse(x, y, 0, 0, false);
ChooseOption('YourMonsterName');
end;
example:
Code:Mouse(x, y, 0, 0, true); //the "false" has been changed to "true"
ChooseOption('YourMonsterName');
end;
All the knowledge you learned is still relevant, except for small changes.
ClickNorth(True) -> SRL_ANGLE_HIGH/SRL_ANGLE_LOW/SRL_ANGLE_NONE
Same goes for SetAngle(True);
Mouse() now uses mouse_Left for left clicking and mouse_Right for right click.
yeah if you learn how to script you learn how to script! yull be a mem in no time (*wink)
thanks for the help, ill give it a try now :)
so i've attempted these methods and still no luck, it right clicks then chooses attack and repeats on the monster after each hit
this is the section I think is causing the problem
Quote:
procedure GMouse(x, y, rx, ry: Integer; left: Boolean);
var
StartX, StartY, TargetX, TargetY, Button: Integer;
DeltaX, DeltaY: Integer;
Neliojuuri, K: Extended;
begin
GetMousePos(StartX, StartY);
GMMouse(x, y, rx, ry);
GetMousePos(TargetX, TargetY);
if left then Button := MOUSE_LEFT
else Button := MOUSE_LEFT;
//else Button := MOUSE_RIGHT;
HoldMouse(TargetX, TargetY, Button);
Wait(25+Round(Gaussian(70, 2.3, True)));
if (Random(15) = 0) then
begin
DeltaX := TargetX-StartX;
DeltaY := TargetY-StartY;
Neliojuuri := Sqrt(DeltaY*DeltaY+DeltaX*DeltaX);
if (Neliojuuri = 0) then MoveMouse(TargetX-1+Random(3), TargetY-1+Random(3))
else begin
K := 1.5/Neliojuuri;
MoveMouse(TargetX+Round((K*DeltaX)), TargetY+Round((K*DeltaY)));
end;
end;
Wait(25+Round(Gaussian(70, 2.3, True)));
ReleaseMouse(TargetX, TargetY, Button);
end;
yeah that's cool, any chance you could give me any clues? just a pointer towards what is causing it