Murdered Cali Swag District member M-Bone may have been targeted after a Twitter war over a girl … sources connected with the group tell TMZ.

Sources say M-Bone’s friends have been in touch with cops, telling investigators after he got back to L.A. from his tour, he got involved with a girl.  M-Bone’s friends say a guy who lived in the woman’s building didn’t like the relationship, and allegedly began threatening M-Bone via Twitter.

We’re told M-Bone did not back down and the two men started cyber smack-talking each other.

TMZ has learned … the black car in which M-Bone was shot is registered to the woman.

Cops are trying to figure out why M-Bone was driving the woman’s car and whether the cyber war is in any way related to the shooting.

And one more important detail.  Witnesses tell TMZ, the shooter fired, left, then pulled a U-turn and came back around, possibly to see if he hit his target.  The upshot — it might not be random, as first suspected.

Stay posted to 24hourhiphop.com for more updates.