Log in

View Full Version : quick explanation



zluo
04-10-2012, 09:56 PM
(findcolortolerance(x,y,2795199,974, 365,1024, 381,20)

can someone tell me what each of the numbers are for? keen to modify a script for my needs

i can understand a few of them are the different colours and one of them is the tolerance but idk where they go

oh and another question. i made my first script for a rsps to chop wood. I want to make it to click on the tree and wait for the stump to appear but i dont know how to make it wait. i currently have this =

procedure Chopping;
begin
if FindColorSpiralTolerance(X, Y, TreeColour, TreeCoordsX1, TreeCoordsY1, TreeCoordsX2, TreeCoordsY2, 2) then

begin
MoveMouse(x, y);
ClickMouse(x,y, 1)
wait
FindColorSpiralTolerance(X, Y, StumpColour, TreeCoordsX1, TreeCoordsY1, TreeCoordsX2, TreeCoordsY2, 2)
end;
end;


so... how can i make it wait?

Runescape Pro
04-10-2012, 10:04 PM
The x and y are variables for the point of where the color will be found. The 7 digit number is the color. The 4 after that are x1, y1, x2, y2. X1, y1 is the top left corner of the search area. X2,y2 is the bottom right corner. Together they make a four sided search "box". The last number is tolerance, i would recommend using ~10.

Theres only o e color but if you can use multiple colors with findcolorstolerance.

Imagine
04-10-2012, 11:01 PM
You can also find out by writing the function yourself:

http://screensnapr.com/e/sPLNGH.png

zluo
04-10-2012, 11:07 PM
imagine how do i do that?

NKN
04-10-2012, 11:43 PM
FindColorTolerance(x,y,2795199,974, 365,1024, 381,20)

x,y = The location where the color is found will be stored here.
2795199 = The color it searches for.
Next four numbers: The "Box" it searches for. It will only search for the color in those, the first number being X1, second Y1, third X2, Fourth Y1.
20 = The tolerance, or how much can the color differ from the original color.

Frement
04-11-2012, 12:02 AM
X1,Y1 is the TOP-LEFT corner, and X2,Y2 is the BOTTOM-RIGHT corner. Just to clarify :)

Imagine
04-11-2012, 12:16 AM
imagine how do i do that?

Uhm it'll usually pop up if you choose the function via ctr+space then write the ( yourself.