The following chord progression has been used to illustrate the four approaches to creating a bass line.
Riff Style: The following example combines three different riffs. For the C major chord, riff 2 is played; for the A and A7 chords, riff 5 is played (a two bar riff) and for the 7th chords a new riff based on the 7th chord arpeggio is played.
Your choice of approach will depend on the "feel" of the song, which incorporates aspects such as melody, rhythm and tempo. For example, the riff style of playing is more suited to a song with a Rock feel, whereas the walking bass may be more suited to a song with a Jazz feel.