I need help at reinforcement schedule and time criterion to end the loop

I have been trying to design an experiment for two weeks and there are two things I need help with. I think you will understand better if I explain the experiment before these two issues:
The experiment consists of 3 phase. The first phase is 10 blocks, the second phase is 8 blocks and the third phase is 4 blocks. Each block is one minute long. In these blocks, participants can press the m and z keys. When the participants press m, the image of junk food will appear and the junk food balance will increase while the money balance will decrease. When they press z, the money balance will increase. We want to achieve this increase with 24 variable rate reinforcement schedules.
The first issue I have difficulty in doing is to make the variable rate reinforcement schedule, the second issue is how to finish these blocks in 60 seconds while recording the response from the keyboard.
I would be very grateful if you can help me with these two issues.

Hello Enver Genco

how many trials do have in a block? You can either restrict the trial duration such that your block ends after 60 seconds, for instance with 30 trials of 2 seconds duration or you start a counter when the block starts and exit the trial-loop when 60 seconds have passed.

You could use an Excel-sheet and loop through this. Specify a column which indicates whether to reinforce in that trial or not.

Best wishes Jens