stefan2200 / TWB

Python based bot for Tribal Wars

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Support messes up troop count

acroticguy opened this issue · comments

I realized that when I have support on my village, the scavenging gets all weird. After some digging some more, I found out that the program "assumes" every unit that doesn't come from my village IS my village's troop count. Here's an example:

I have received 1 spear and 1 sword.

I have 500 spear, 200 sword, 100 axe.

The program will think I have 1 spear, 1 sword, 100 axe (It was my first assumption, confirmed with debug logs).

I haven't yet toyed with the extractors.py file, but I intend to figure out a fix. A simple idea would be to have the bot count. On the "units_home" table, the 2nd row corresponds to units "From this village", and the units count starts from the 4th column.

I'll update this issue once I have more information on the problem. If I do end up fixing it fast, I'll simply request a PR

Closing, PR request is up.