You can do that with cell command on cell 16, than go to new PGC. Set R value at the beginning of second PGC.
At the end of play use Link to first PGC. PreCommand of first PGC will have Condition using your R value and Link to cell 17.
At the end of first PGC play, set your R value to zero.
This is a work flow, rest may be your home work.