Evolution of attractors in quasiperiodically forced systems: From quasiperiodic to strange nonchaotic to chaotic