SRL Archive - Help

FindObjCustom Error


mrbarrybadger

2012-06-02 13:32:43

Basically when I run my script it identifies and picks up the object a few times and then this error appears

Warning! You passed a wrong ys to a finder function: -5. That is below 0, thus out of bounds. Setting the value to 0 for now.

And it goes to shit :P I'm not sure how to resolve this because im fairly new to writing scripts but here is the code that I think its having problems with and it is the only findobj in the script

var
x, y: Integer;
begin
if FindObjCustom(x,y,['Take'],[2455111,2058038],5) then

thanks in advance

Google

2012-06-02 13:47:22

This is a common problem for all the includes findobj functions its just from the script trying to search outside the client for the color. You can just try lowering the tolerance a little more or setting bounds on where to search for the item. Or you can always create your own function which are much more accurate and faster.

mrbarrybadger

2012-06-02 17:17:28

Ok Thank You Very Much Using ACA now which cleared it all up thanks :)