New question #226773 on Sikuli:
https://answers.launchpad.net/sikuli/+question/226773
Hi guys,
I have been trying to teach myself sikuli and jython by trying myself at
writing a program to play bejeweled for me . Sort of reverse engineering the
bejeweled script that is on the sikuli video section (I have 0 coding
experience, but with the help of the people here on LaunchPad especially RaiMan
I have muddled my way through). I have the most basic up and running (scans
bejeweled in about 5 seconds (best i could manage) and does a move (prioritizes
5 in a row over 4 over 3). However i find that the program gets stuck very
often because it seems the click on the first gem is not successful 100% of the
times.
I have the code:
def perform_Clicks((a,b),(c,d)):
mouseMove(Location(a,b))
mouseDown(Button.LEFT)
mouseUp()
mouseMove(Location(c,d))
mouseDown(Button.LEFT)
mouseUp()
with a,b being the coordinates for gem1, and c,d the coordinates for gem2.
The mouse moves to the right gem, but the gem only becomes 'highlighted' due to
a click about 50% of the times.
I tried putting a wait command between the move and the click, but it didn't
improve things.
When i click on the gem by my mouse-pad it is 100% successful on the first try.
Any ideas how I can improve this?
--
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.
_______________________________________________
Mailing list: https://launchpad.net/~sikuli-driver
Post to : [email protected]
Unsubscribe : https://launchpad.net/~sikuli-driver
More help : https://help.launchpad.net/ListHelp