sikuli-driver team mailing list archive
-
sikuli-driver team
-
Mailing list archive
-
Message #12848
[Question #207372]: Create Region from Match/Speeding up Searches!
New question #207372 on Sikuli:
https://answers.launchpad.net/sikuli/+question/207372
I am trying to create a sikuli script that plays a memory card game.
My current code works, however the game has a timer and it times out searching through my array. I was hoping there is a faster way to search for an image.
My current basic code:
cards = [images of each possible card] # eg [card1.png, card2.png]
areas = [matches of each area] # each area is a match taken from a reference point image and then using the offset feature.
for area in areas:
click(area)
for card in cards:
if exists(card, 0)
match.append((area, card))
Ideally I want to make it so it only searches in the area for the correct card. And before you ask, no I cannot simply define a region for each card area. I have put a personal ban on using regions defined by coordinates as they seem to break our tests when run in a different resolutions.
Regards,
Andrew
--
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.