Basically, I composed the musical structure in one pass. The rest was editing and small adjustments. And when the play was read by actors with the music, the sequence timed-out perfectly.