
Originally Posted by
Ashaman88
Nice how is that working for you? If you grab a bunch of pics from different instances of the crystal dealios (only need 1 pic per instance) I can add in a more reliable detection.
Not sure how to "mention" you in this so I'l just quote you 
So I worked on that nest finder and I got it working. Picked up 2 of the 2 nests that fell out of the ivy. The final code is:
Simba Code:
function findNest(): Boolean;
var
nestTextDTM, x, y, i: Integer;
TPA: TPointArray;
ATPA: T2DPointArray;
begin
if not isLoggedIn() then
exit();
nestTextDTM := DTMFromString('mFQEAAHicnc29CoJgFMbx57ziECm6hJRjbU1NCVpWQ5uX4sV2KdkUBPpPXgfHOvDjfDzDiSXtnLTHAUdccEeDDDlifEx6wTHXKHHFye/TfEOFs7+VPo82W/X8ewTh2L86c3qb6YliESlcJupcMGZtutKa/iv7w6wGWYgSbg==');
if findDTM(nestTextDTM, x, y, chatBox.getBounds()) then
begin
if findColorsSpiralTolerance(x, y, TPA, 3099216, mainScreen.getBounds(), 7, colorSetting(2, 0.34, 1.21)) or //Bird's Nest color
findColorsSpiralTolerance(x, y, TPA, 15774489, mainScreen.getBounds(), 10, colorSetting(2, 0.02, 1.23)) then //Geode Color
begin
if (length(TPA) < 1) then
exit();
ATPA := TPA.toATPA(30, 30);
ATPA.filterBetween(0,200);
if length(ATPA) < 1 then
exit();
ATPA.sortFromMidPoint(mainscreen.playerPoint);
smartImage.debugATPA(ATPA)
for i := 0 to high(ATPA) do
begin
mouse(middleTPA(ATPA[i]), MOUSE_MOVE);
if isMouseOverText(['Take Bird', 'Take Crystal'], 1000) then
begin
fastClick(MOUSE_LEFT);
break();
end;
end;
end else
writeLn('Found text but didn''t find any colours');
end;
freeDTMs([nestTextDTM]);
end;
I missed one Crystal Geode, the only one that fell. I didn't see what happened, but I assume it detected the text but didn't see the Geode itself so I lowered the ATPAfilerbetween to see if that would help.
I put it in your ivypresent function so it would be called continuously. The problem I have now is if that is the best place to put it? Also, once it picks up the nest it just sits there, this is probably from it seeing the text that the nest/geode fell out of the ivy and it keeps looking for them. I am sure you know what to do.
I am sure people would really appreciate this being in your script. I will try and fiddle with it to see if I can figure something else out. Race to see who can do it first? hahaha
EDIT:
While I am at it I found an issue in the script too. It will be cutting the ivy for a while without having to switch and all of a sudden it will show this code:
Code:
Too much time has passed, finding new ivy!
Attempting to log back in
-- TPlayer.login()
---- ERROR: TPlayer.loginToLobby(): Failed to find username and/or password box
---- ERROR: TPlayer.loginToLobby(): Failed to find username and/or password box
---- ERROR: TPlayer.loginToLobby(): Failed to find username and/or password box
---- ERROR: TPlayer.loginToLobby(): Failed to find username and/or password box
---- ERROR: TPlayer.loginToLobby(): Failed to find username and/or password box
---- ERROR: TPlayer.loginToLobby(): Failed to find username and/or password box
---- ERROR: TPlayer.loginToLobby(): Failed to find username and/or password box
---- ERROR: TPlayer.loginToLobby(): Failed to find username and/or password box
---- ERROR: TPlayer.loginToLobby(): Failed to find username and/or password box
---- ERROR: TPlayer.loginToLobby(): Failed to find username and/or password box
---- ERROR: TPlayer.loginToLobby(): Failed to find username and/or password box
---- ERROR: TPlayer.loginToLobby(): Failed to find username and/or password box
---- ERROR: TPlayer.loginToLobby(): Failed to find username and/or password box
---- ERROR: TPlayer.loginToLobby(): Failed to find username and/or password box
---- ERROR: TPlayer.loginToLobby(): Failed to find username and/or password box
---- ERROR: TPlayer.loginToLobby(): Failed to find username and/or password box
---- ERROR: TPlayer.loginToLobby(): Failed to find username and/or password box
---- ERROR: TPlayer.loginToLobby(): Failed to find username and/or password box
---- TRSLobby.getCurrentTab(): Current tab is 0
---- TRSLobby.quickSelectWorld(): Found worlds [81, 52, 1]
---- TRSLobby.quickSelectWorld(): Clicked world 52. [Index 1]
------ TRSActionBar.__findButton(): Found the actionbar button @ {X = 566, Y = 435}
------ TRSActionBar.__find(): result = true (height = 37)
------ Dynamic interfaces have been set.
---- Logged in: XXXXXXXXXX
-- TPlayer.login(): True
and then it will log the player out and re log in.