How to align images with Sikuli Automation

Asked by Nobody

I'm trying to automate a simple game which has mini games in it. I'm trying to automate 2 mini games which i have trouble doing.

1. matching the color in the center with the color on the side. Let's assume X is the color in the center.


So if X on the bottom matches the center, I need to swipe down. If X is on the right, then swipe. The image are similar but on the side is a 'long' version of the image in the center. How can i do that?

2. Aligning images (sort of like 4 in a row game)


basically the center row can be dragged left or right. I need to align the ABC to the top and bottom. How can I do that in sikuli?

I'm using the IDE to do that. So the language is jython i believe.

Question information

English Edit question
SikuliX Edit question
No assignee Edit question
Last query:
Last reply:
Revision history for this message
RaiMan (raimund-hocke) said :

Not really clear what your problems are.

Something to watch (link, image samples, code snippets, ...) would be helpful.

Revision history for this message
Nobody (nobodyz) said :

here is for part 2.

basically, i need to drag the center line left/right to align to the top and bottom.
i dont have any code snippets yet, still trying to figure out how to start..

Revision history for this message
RaiMan (raimund-hocke) said :

here is something to play with:

- unzip
- open the in the IDE
- make the image align.png visible in a frontmost window
- realign the gameTop region to your screen layout
- run the script

try to understand, what's going on ;-)

Revision history for this message
Nobody (nobodyz) said :

Thanks @RaiMan! Will take a look!

Can you help with this problem?

Provide an answer of your own, or ask Nobody for more information if necessary.

To post a message you must log in.