Page 1 of 2
Auto farm sortation
Posted: 05 Feb 2018, 12:54
by TravibotUser
Hi Vlad,
I am quite satisfied how the TraviBot is working, although I think there is some room for improvement to optimize autofarm.
Can you explain a few things?
1. When starting the raids, how are the farms sorted?
2. If there are not enough troops for all farms, how will they be sorted the next time?
3. How is average farm per hour calculated?
Thank you
Re: Auto farm sortation
Posted: 05 Feb 2018, 18:33
by TravibotUser
I have been thinking of a way to evaluate the average farm per hour, and I think currently its not right. Im not sure how exactly it is calculated currently, but it gives way too high numbers.
My idea is:
Total farm / ((Time of 1 attack(both ways, i.e. including return) * attack count) / 60min)
For example, if my total is 10000, attack count is 10, it means 1000 per attack. If an attack takes 20 minutes one way + 20 minutes to come back, it means i get 1000 per 40 minutes. 1000 / (40 / 60) is 1500, which makes sense.
Re: Auto farm sortation
Posted: 07 Feb 2018, 16:08
by Vlad
1 Sorted by farm per hour, exclude farms where interval from last sending not gone
2 Sorted in the same way
3 Total bounty/(troops movement in hours*2*raid count)
Re: Auto farm sortation
Posted: 07 Feb 2018, 17:41
by TravibotUser
The formula in 3rd is not how the bot calculates it.
Example:

I am Gaul and as you can see I am raiding with 4 TT's, distance is 3, one way it takes 9 minutes and 28 seconds, or 0.158 hours.
So the average farm per hour would be 17742 / (0.158 * 2 * 120) = 467.87
However, the bots says 21736
Also, when there are not enough troops, dont you think the bot should firstly sort by last raid time? Because otherwise some of the farms might be never reached.
Re: Auto farm sortation
Posted: 07 Feb 2018, 18:03
by Vlad
May be time calculated without return time, I do not remember, but bot analyze last 20 (if I remember right) of reports to calculate this value, not all of them
Order more troops, and all will be reached
No sense in reaching farm with bad bounty, if we can send troops into farms with good bounty
Re: Auto farm sortation
Posted: 07 Feb 2018, 19:57
by TravibotUser
But Vlad, even if it calculates without return time, this number of 21736 does not make sense. Could you have a look at the calculation?
Re: Auto farm sortation
Posted: 08 Feb 2018, 13:30
by Vlad
What I should to see?
Formula from sources
((Bounty - Lost) / AttCount) / WayHours;
Where
Bounty: bounty from last 20 reports
Lost: Cost of dead troops from last 20 reports
AttCount: Attack count
WayHours: hours in one side
Re: Auto farm sortation
Posted: 08 Feb 2018, 14:42
by TravibotUser
You should see a mistake in the source code. Maybe the travel time is calculated wrong? I dont know
Example from the same farm that I added yesterday:

These are the last 20 reports. The bounty is 2709. Loss = 0. The attack count is 20.
So according to the formula from your sources:
((2709 - 0) / 20) / 0.158 =
857.27
Not anything near
20603.
Also, could you multiply the hours by 2 to include the return as well?
Re: Auto farm sortation
Posted: 08 Feb 2018, 15:01
by Vlad
Send me your Logs.mdb file, I will check
No any sense in multiply
Re: Auto farm sortation
Posted: 08 Feb 2018, 15:19
by TravibotUser
I have sent you a PM with url to download the logs file.
I think it makes sense to include the total time of troop travel, not only one way.