Inquisit code:
<defaults>
/quitcommand = (Ctrl+'e')
/fontstyle=("Arial", 3%)
</defaults>
<values>
/accuracy = 50
</values>
<parameters>
/pictures_size = 30%
/pictures_position = 50%
</parameters>
### Define the stimuli
<item stimlistA>
/1 = "wpa4_stimuli/patch1.png"
/2 = "wpa4_stimuli/patch2.png"
/3 = "wpa4_stimuli/patch3.png"
/4 = "wpa4_stimuli/patch4.png"
/5 = "wpa4_stimuli/patch5.png"
/6 = "wpa4_stimuli/patch6.png"
/7 = "wpa4_stimuli/patch7.png"
/8 = "wpa4_stimuli/patch8.png"
/9 = "wpa4_stimuli/patch9.png"
/10 = "wpa4_stimuli/patch10.png"
/11 = "wpa4_stimuli/patch11.png"
/12 = "wpa4_stimuli/patch12.png"
/13 = "wpa4_stimuli/patch13.png"
/14 = "wpa4_stimuli/patch14.png"
/15 = "wpa4_stimuli/patch15.png"
</item>
<item stimlistB>
/16 = "wpa4_stimuli/patch16.png"
/17 = "wpa4_stimuli/patch17.png"
/18 = "wpa4_stimuli/patch18.png"
/19 = "wpa4_stimuli/patch19.png"
/20 = "wpa4_stimuli/patch20.png"
/21 = "wpa4_stimuli/patch21.png"
/22 = "wpa4_stimuli/patch22.png"
/23 = "wpa4_stimuli/patch23.png"
/24 = "wpa4_stimuli/patch24.png"
/25 = "wpa4_stimuli/patch25.png"
/26 = "wpa4_stimuli/patch26.png"
/27 = "wpa4_stimuli/patch27.png"
/28 = "wpa4_stimuli/patch28.png"
/29 = "wpa4_stimuli/patch29.png"
/30 = "wpa4_stimuli/patch30.png"
</item>
<picture A>
/items = stimlistA
/select = noreplace
/position = (parameters.pictures_position, parameters.pictures_position)
/size = (parameters.pictures_size, parameters.pictures_size)
</picture>
<picture B>
/items = stimlistB
/select = noreplace
/position = (parameters.pictures_position, parameters.pictures_position)
/size = (parameters.pictures_size, parameters.pictures_size)
</picture>
### Define the trial elements
<trial trialA>
/stimulustimes = [1=A]
/validresponse = ("a", "b")
/correctresponse = ("a")
/pretrialpause=1500
/errormessage = true(wrong, 500)
/correctmessage = true(right, 500)
/ontrialend = [values.accuracy = (trial.trialA.percentcorrect + trial.trialB.percentcorrect)/2]
</trial>
<trial trialB>
/stimulustimes = [1=B]
/validresponse = ("a", "b")
/correctresponse = ("b")
/pretrialpause=1500
/errormessage = true(wrong, 500)
/correctmessage = true(right, 500)
/ontrialend = [values.accuracy = (trial.trialA.percentcorrect + trial.trialB.percentcorrect)/2]
</trial>
<text right>
/items=("CORRECT!")
/position = (50%, 50%)
/hjustify = center
/fontstyle=("Arial", 10%)
/txcolor=(0,0, 255)
</text>
<text wrong>
/items=("INCORRECT!")
/position = (50%, 50%)
/hjustify = center
/fontstyle=("Arial", 10%)
/txcolor=(255,0, 0)
</text>
### Define pages
<page final_message>
Congratulations!
^^ You finished the experiment.
^^ You maintaned a performance of <%values.accuracy%> percent.
</page>
### Define the block and exp elements
<block choice_block>
/trials = [1-30=noreplace(trialA, trialB)]
/postinstructions = (page.final_message)
</block>
<expt>
/blocks = [1=choice_block]
</expt>