← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #321908]: help with else

 

Question #321908 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/321908

    Status: Open => Solved

gibleis confirmed that the question is solved:
I posted to soon and actually just got it to work.  Simple formatting
errors on my part.  In case it helps anyone else who sees this thread,
this is how I got it to work.

setFindFailedResponse(SKIP)

while True:    
    click(Pattern("1470112829847.png").similar(0.90).targetOffset(-207,3))
    click(Pattern("1470112829847.png").similar(0.90).targetOffset(-136,39))
    click(Pattern("1470112829847.png").similar(0.90).targetOffset(-74,81))
    click(Pattern("1470112829847.png").similar(0.90).targetOffset(-10,123))
    click(Pattern("1470112829847.png").similar(0.90).targetOffset(68,150))
    click(Pattern("1470099385638.png").similar(0.50), 1)
    click(Pattern("1470099385638.png").similar(0.50), 1)
    click(Pattern("1470099385638.png").similar(0.50), 1)
    click(Pattern("1470141710780.png").targetOffset(-75,82))
    if exists("1470141893102.png"):
        click("1470141893102.png")
        click(Pattern("1470273708861.png").similar(0.80).targetOffset(1,40))
    if exists(Pattern("1470142033137.png").similar(0.90)):
        click(Pattern("1470142033137.png").similar(0.90))
    else:
        click(Pattern("1470273980387.png").similar(0.80))        
        click(Pattern("1470273855648.png").similar(0.80).targetOffset(0,39))
        click(Pattern("1470273898075.png").similar(0.80))
    click(Pattern("1470099385638.png").similar(0.50), 1)
    click(Pattern("1470141710780.png").targetOffset(-79,185))
    if exists("1470141893102.png"):
        click("1470141893102.png")
        click(Pattern("1470273708861.png").similar(0.80).targetOffset(1,40))
    if exists(Pattern("1470142033137.png").similar(0.90)):
        click(Pattern("1470142033137.png").similar(0.90))
    else:
        click(Pattern("1470273980387.png").similar(0.80))        
        click(Pattern("1470273855648.png").similar(0.80).targetOffset(0,39))
        click(Pattern("1470273898075.png").similar(0.80))
    click(Pattern("1470099385638.png").similar(0.50), 1)
    click(Pattern("1470141710780.png").targetOffset(-77,280))
    if exists("1470141893102.png"):
        click("1470141893102.png")
        click(Pattern("1470273708861.png").similar(0.80).targetOffset(1,40))
    if exists(Pattern("1470142033137.png").similar(0.90)):
        click(Pattern("1470142033137.png").similar(0.90))
    else:
        click(Pattern("1470273980387.png").similar(0.80))        
        click(Pattern("1470273855648.png").similar(0.80).targetOffset(0,39))
        click(Pattern("1470273898075.png").similar(0.80))
    click(Pattern("1470099385638.png").similar(0.50), 1)
    if exists(Pattern("1470113950787.png").similar(0.90).targetOffset(1,87)):
        doubleClick(Pattern("1470113950787.png").similar(0.90).targetOffset(1,87), 0)
        click(Pattern("1470114166301.png").similar(0.90), 0)
        click(Pattern("1470114252503.png").similar(0.90), 0)
        
    if exists(Pattern("1470114320553.png").similar(0.90).targetOffset(4,81)):
        doubleClick(Pattern("1470114320553.png").similar(0.90).targetOffset(4,81), 0)
        click(Pattern("1470114166301.png").similar(0.90), 0)
        click(Pattern("1470114418489.png").similar(0.90), 0)

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.