And to add, you may be locked on a heading but appear to be tracking the SID/STAR anyway - Aircraft on own navigation can deviate from the SID/STAR (I have seen it) whereas, when locked on a heading, they can't (or shouldn't). If someone is being climbed through your level 3nm (or perhaps sometimes further) offset from the SID/STAR track, expect to be locked on a heading so that this can be done. (Aircraft can wander off...
)
Cheers,
DF