OnceBot - Elvenar Bot


#1

Hi

Do you stop developed oncebot ?


#2

Hello,

last developed version of OnceBot was v16.05.01. Since then I did not make any changes to this bot.


#3

It seem’s that have a little bug , bot will click on workshops after 5 mins work is finished but will not reset next 5 mins.

The weird thing is it start the production but it doesnt collet it after the 5 mins


#4

bot will click on workshops after 5 mins work is finished

I do not understand this part. Is there something missing here?


#5

Let me reformulate with a picture

So on workshops and factorys if they are inactive and have that Zzz on top (red circle) , the bot will click and choose the production that takes less time in the case of workshops it will choose 5 minutes , and in the factorys the 3 hours option.

But when they finished (blue circle) the bot do not collected them , and do not start another production.


#6

I see. The bot is using image processing to detect the icons in the game window. The behaviour you described could result from the bot not recognizing the finished goods icon anymore.

The bot should display a text containing a list of all icons it found, with a name and location for each.

I suggest the following experiment:

  • Take a screenshot and copy one of the sleeping icon and one of the finished icon in a new image.
  • Then point the bot to a window containing this artifical image.

What is then shown in the textbox in the bot?

Another question not related to the experiment: Does the appearance of the icons depend on the level of the building?


#7

What is then shown in the textbox in the bot?

Another question not related to the experiment: Does the appearance of the icons depend on the level of the building?

For what i see at naked eye ( portuguese expression ) , no . They all seem equal. Even between factorys or workshops


#8

Maybe innogames changed the icon.

Can you send me an uncompressed version of that image?


#9

Well i try some things to get that icon , but my knowhow its limited , if you can point me the way to do it i will try.

edit: I found this image in their forum , but i dont have sure if it is this one

https://pt.wiki.elvenar.com/images/6/62/Supply_small.png


#10

Perhaps I was not clear abput what I meant with image.

To adjust and test the code, I work with samples taken from screenshots of the game. Access to the original icon is not required.

Please send me a screenshot that contains at least some buildings with finished goods. I could take this as a sample to test against.


#11

This one have the workshops and the factorys ready to collect

http://i.imgur.com/2N6FnU3.jpg


#12

This file looks like it was compressed with jped. I would prefer to use an uncompressed sample. Please save a screenshot as png.


#13

Now in png format , could you take samples from the factorys too ? The elixir , cristal and steel factorys , happens the same as the workshops.

https://s12.postimg.org/6gx5yyedp/print_elvenar.png


#14

Hello Dreamsoul,

I noticed that at the moment I do not have access to the OnceBot project files I normally use for development. I will take a look at the icon recognition when I get a hold of those. This is probably not going to happen before december.


#15

Sad news

We will wait until december.

I will using the macros that I made for a mouse clicker.


#16

Maybe I should start reading the flash players memory for sensing instead of processing screenshots.


#17

If I can help in some way , just tell me how to do it


#18

If I can help in some way , just tell me how to do it

If we want to adjust the existing bot to find the new icon, we will need some algorithm to determine the location of the icon in a screenshot. With the tools I have so far this requires time to try out different patterns / combinations.

Is this understandable so far?

Have you already worked with image processing?


#19

Yes its more or less understandable.

No , never worked with image processing .


#20

Well, this process of finding a suitable pattern for a given icon is the only challenge I see so far to adding support for collecting all kind of items, elixir, cristal and steel and so on. In other words, if you can do that, you can let the bot collect all of them. (Starting a production alwas happens at the same kind of Icon, so that should already be covered)

Currently the localizing of the icons works like this:

Independently for each pixel in the searched region, it is decided whether this pixel belongs to a particular icon (After this, some postprocessing aggregates pixels which have been classified the same and are close to each other, but this part is not of much importance here).

The decision per pixel is made by a list of constraints on the colors of neighbours of the pixel.