Nightmare0
Active Member
when i run this script:
it compiles and runs, but doesn't do anything. my colors are correct, and even when i switched and replaced stuff to make this:
it goes and right click on the object, but doesn't choose attack, just hovers there until the repeat.
im just messing around with a private server to learn more about scripting so the commands don't have to be completely anti-ban stuff, just basics.
if you can help me pls respond
Code:
program ColorAndTextClick;
{.include SRL/SRL.scar}
Procedure Clickity;
var
x,y:integer;
begin
FindObj(x,y,'the uptext',555{<- the color},3{<-the tolerance})
GetMousePos(x,y);//gets the current x,y co-ords
Mouse(x,y,3,3,false);//clicks the mouse at x,y right click
ChooseOption('option');//option you wanted eg 'Take iron'
end;
begin
SetupSRL;
Clickity;
end.
it compiles and runs, but doesn't do anything. my colors are correct, and even when i switched and replaced stuff to make this:
Code:
program ColorAndTextClick;
{.include SRL/SRL.scar}
var
x,y: integer;
const
dragon=5123099;
Procedure Clickity;
begin
if(FindColor(x,y,dragon,0,0,600,600)) then
begin
MoveMouseSmooth(x,y);
ClickMouse(x,y,false);
ChooseOption('attack');//option you wanted eg 'Take iron'
end;
end;
begin
SetupSRL;
repeat
Clickity;
Wait(4000);
until(IsFKeyDown(8));
end.
it goes and right click on the object, but doesn't choose attack, just hovers there until the repeat.
im just messing around with a private server to learn more about scripting so the commands don't have to be completely anti-ban stuff, just basics.
if you can help me pls respond


