function coopHenEvalFunc(address)
-- Don't target hens in the ignore list
for k,v in pairs(ignoredHens) do
if v.address == address then
if Timeout == 0 or (Timeout > 0 and Timeout > (os.time() - v.time)) then
return false
end
end
end
local hen = CObject(address)
-- Only target coop Hens
if 3240 > CObject(address).Z then return false end
-- Don't target moving hens
local oldX, oldZ = hen.X, hen.Z
yrest(100)
hen:update()
if distance(hen.X,hen.Z,oldX,oldZ) > 2 then return false end
return true
end
exactly
btw this is what causes the bot gettig stuck at the barn collumn (at least i think so cause it got stuck before and doesnt now)
I tried the new code for the hens and it does work but it really slows the process down. At times the bot will stop and look/rotate around and hesitate for 5+ seconds until it finally finds a new hen.
i just tested it and realised it's imposible to target a hen leaving the coop. After it encourages the hen it picks up the egg. By the time it picks up the egg. the hen is long gone.
How exactly is it targeting a moving hen?
BTW I din't see any 5 second hesitations.
Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
i dont know how but it does sometimes (like once in 1k hens) run after a leaving one and crash into that column...where it gets stuck 4 a while...
more often the bot dont crashes the column but runs after a leaving hen feeding it and returns into the barn just to leave it again to go feeding hens...
i know this may sound stupid but i saw the bot do so more than twiche before i added those lines, and now he behaves...
local currchar = RoMScript("CHARACTER_SELECT.selectedIndex")
ChangeChar(currchar)
The other code worked but it would every now and then crash the client, so far the above one hasn't yet (knock on wood). I also noticed what was happening was the bot eventually would get stuck and use the code to log out, then back in, and then the bots would get stuck walking back to the farming area. So I added 8 way points with ports to get the bot to the farming area and so far its helped a lot. The one question is, is the code for stuck eggs working? I appears my bots just stop once they can't find a egg.
So after 2 days running the above code and I am seeing something I have not seen in the past, every once in a while one of two things happens: 1) The chat window is open and full of QQQQ's. 2) Its at the login screen with a bunch of QQQ's in the account name. Any idea why this would happen?
bobdole wrote:The one question is, is the code for stuck eggs working? I appears my bots just stop once they can't find a egg.
The original code shouldn't stop if it can't find an egg but it does stop if all the hens are on the ignore list. It waits for some time, I don't remember if it's 5 or 10 minutes, then tries again.
local currchar = RoMScript("CHARACTER_SELECT.selectedIndex")
ChangeChar(currchar)
Do you have to reload the file again here so that it enters Millers again?
bobdole wrote:1) The chat window is open and full of QQQQ's
That would happen if it's trying to turn with the 'q' key. Are you using "quickturn"? The chat box might be openning because you pressed the shift key while doing something else and when the bot presses 's' to move back, it becomes a SHFT-S which opens chat for "say". Try changing the hotkey in the key bindings in the game system menu for "Say".
bobdole wrote:2) Its at the login screen with a bunch of QQQ's in the account name
Probably you had a loss of communication so it dropped to the log in screen and the bot didn't realise it and kept pressing 'q' to try to turn you.
Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
I can't seem to get it to harvest. It is running the path fine, teleporting fine, and detecting feedbags and chickens fine, but it just keeps saying "Feedback/Ranch Hen founnd. Will attempt to harvest now." Or something like that. But it doesn't actually harvest it! Why is this, and how can I fix it?
Well it seems to be the simple case that you haven't selected "Click To Move" in the game options.
Cause character moves everywhere using the "W" key, but to harvest it clicks to move, so probably you don't have that option on.
No, I had that selected. It seemed that once I installed the teleport userfunction and turned that on in the MRC_optimized waypoints, it started working. o.O weird, but I am just glad it works
I am having real big problems with running bots on my laptop as of late. They do great for a while and then hens are getting stuck in the house. This doesn't happen on my desktop so I am confused why it would happen. I know the script keeps track of stuck hens while feeding but does it keep track of the stuck ones in the hen house? I come back a lot to the bot just standing at the hen house doing nothing and would love some suggestions how to fix it.
We don't really know what causes stuck hens and eggs so can't say why you are getting stuck hens in the coop. We didn't used to get stuck hens in the coop, that's why there is no check for it.
The only thing I noticed is when I was running a few millers eggs at once, I would occationally get stuck eggs. But now that I only ever run one at a time, I never get anything stuck. I suspect it has something to do with running too many millers at once even though it seems like your pc can easily handle the cpu and memory load. Try running fewer and see if that help. I don't know if this will help as every time I suggest this no one ever comes back to say if it worked or not.
Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
I stopped using my model file and I think that's brought back of lag on the bots so test with model back on. My other issue is I always have one bot that gets stuck trying to feed a hen and wont go back to the feed, any setting I can make a longer delay or something to try and resolve that?
Now several bots are getting stuck trying to feed the hens and wont go back to the feed, any setting I can make a longer delay or something to try and resolve that?