My dynamic music is based on timers, I never use looping. It plays a chain of segments and checks pre-defined conditions after each one to determine which segment should be played next. The second way is using layers. Simply play multiple tracks with the identical duration at the same time and control their volume dynamically.