Which was that function that you telled: if a color is Somewhere (x , y) then
do something else.
Which was that function that you telled: if a color is Somewhere (x , y) then
do something else.
function Getcolor(x, y): integer;
That it?
Interested in C# and Electrical Engineering? This might interest you.
dunno but I´m not needing to get the color, I need to find one color in one place (specified) and then if found that color, do something else.
Are you trying to find the coordinates of a number? if so...
Is that what you're looking for?Code:var x,y: Integer; begin findcolor(x,y, <color>,0,0,6000,6000 end;
you make one.
SCAR Code:if FindColor(x, y, {color}, {coord1 x}, {coord1 y}, {coord2 x}, {coord2 y}) then
begin
DOTHIS;
end;
EX.
SCAR Code:{.include srl/srl.scar}
var
x, y : Integer;
begin
if FindColor(x, y, 0, 0, 0, 100, 100) then MMouse(x, y, 0, 0);
end.
//if it finds the color 0 in the box made by the coordinates then it will move the mouse to that location
If I write it with my not-knowing knowledge, I think it´s something like this :
If findcolor 2342340 on x,y then writeln(hi there); but it doesn´t works like this.
but isnt there a function like this one:
if Findcolor(3124324, [exact coordinate (12,543)] then
begin
writeln(need to do this);
end;
You can do:
SCAR Code:if (GetColor(x, y)=0) then
begin
writeln('need to do this');
end;
where x and y are the coords and 0 is the color
I have one that I just made. All I ask is minor credits:
SCAR Code:function GetColorAt(x,y,color: integer): integer;
begin
if (GetColor(x, y) = color) then
begin
Writeln('Found color.');
end;
end;
Hope this helps
Edit: Derek- you beat me to this lol!
Formerly known as Cut em2 it
Thanks guys, this solved my problem
There are currently 1 users browsing this thread. (0 members and 1 guests)