i need help with my mining script, what i need help with is when i want to move mouse to the rocks in Rimmington not to go over to the iron on the floor, plz post ur ideas on how I can exclude the ores when finding rocks ?
i need help with my mining script, what i need help with is when i want to move mouse to the rocks in Rimmington not to go over to the iron on the floor, plz post ur ideas on how I can exclude the ores when finding rocks ?
What I would do is when I find the location where I think the color is at (x,y):
SCAR Code:var
TPA: TPointArray;
FindColorsSpiralTolerance(mx,my,TPA,2958623,x-15,y-15,x+15,y+15,5);
if(GetArrayLength(TPA) > 15)then //Must be a rock and not an ore if there's that many colors
Mouse(x,y,3,3,true);
Something like that? Where I think I found the rock at, check the amount of colors in that area (with a tolerance of 5), and if there's a lot, we know it's not the iron on the ground, but the rock. You may need to learn TPA's to understand that better (there are many tutorials on it in the advanced section of tutorial island).
Last edited by JAD; 08-14-2009 at 02:50 AM.
Or you can use reflection and simply find a object with 100% accuracy and efficiency.
well i tried doing that way see if it is in a range but when i tried working out my ranges they where CRAZY they ranged from 200 -500 (iron ore on floor)
Edit :> i don't want to use reflection :P
my brain has reached the limit need help :Por he could use his brain instead of taking the easy way out...
your brain hasn't reached any limits, your just being lazy. Which is probably the number 1 downfall to most scripters..
What JAD told you should work.
To help explain what he said though...he is just counting how many times it found the rock color inside the search area, and if it is over 15 in this case, it will click it thinking that it is the rock.
Last edited by NCDS; 08-14-2009 at 03:18 AM.
15 is not an accurate number, it was just an example. And the iron ore on the ground might actually have more of the color then the rock itself, in which case you would do the opposite (if GetArrayLength(TPA) < 15 then it's the rock, for example). Just don't use too much tolerance or too big of a box around the point and you shouldn't get too many colors.
@NCDS hmm maybe ur rite but i think jad ur way is working for a start but how do i make it not to go over to the coords of iron on floor?
Edite :> NVM SOlved my problem
Last edited by hackncrack1; 08-15-2009 at 03:18 AM.
There are currently 1 users browsing this thread. (0 members and 1 guests)