This is how Optimus and Twilight meet Sunset Shimmer goes in My Little Pony: Equestria Girls.
[Optimus and Twilight walk through a corridor when they hear someone talking]
Sunset Shimmer: Hey! You leave her alone!
[Optimus and Twilight look round a corner and see a red and yellow haired girl standing facing Thunderwing]
Optimus Prime: Who is she?
Twilight Sparkle: I don't know.
[They walk up behind the girl to watch her face Thunderwing]
Sunset Shimmer: Leave her alone!
Thunderwing: Or what?
Sunset Shimmer: Or... [turns and sees Optimus and Twilight behind her] Or I'll ask those two to kick your butt!
Thunderwing: [studies Optimus and Twilight for a moment then smirks] They must be new here. [flicks Twilight's nose and pushes Optimus aside before leaving] I can speak to anyone, any way I want.
[Optimus and Twilight watch Thunderwing glare at a student then disappear round a corner. The girl with red and yellow hair goes over to a girl with pink hair and a butterfly hairclip and helps her to her feet]
Sunset Shimmer: Are you okay?
Fluttershy (EG): Yes. Thanks to you and your new friends.
[Twilight and Optimus come over]
Optimus Prime: Uh, excuse me?
Twilight Sparkle: That was very brave what you did back there.
Sunset Shimmer: Thanks. But I can't believe you guys just did that.
Optimus Prime: Well, we could not just stand there doing nothing.
Twilight Sparkle: I'm Twilight Sparkle and this is Optimus Prime.
Sunset Shimmer: Nice to meet you two. But I've gotta tell you something: Nobody ever stands up to Thunderwing.
Optimus Prime and Twilight Sparkle: Thunderwing?!
Sunset Shimmer: You've heard of him?
Optimus Prime: He's Unicron's most loyal and powerful follower.
Twilight Sparkle: Well. sorta.
Sunset Shimmer: What brings you guys here?
Optimus Prime: We came here seeking a crown.
Twilight Sparkle: I think I heard Thunderwing saying it belonged to him.
Sunset Shimmer: Yes. Fluttershy here gave it to Principle Celestia.
Optimus Prime: Principle? Don't you mean Princess?
Twilight Sparkle: [nudges him] I told you not to mention anything about where we're really from.
Sunset Shimmer: What are you talking about?
Optimus Prime: Oh, nothing personal.
Twilight Sparkle: We just need to ask Principle Celestia about that crown.
Sunset Shimmer: Then let me help you.
Optimus Prime: That would be most helpful, young one.
Twilight Sparkle: Yes, very helpful.
Sunset Shimmer: And by the way, my name's Sunset Shimmer.
Twilight Sparkle: Nice to meet you, Sunset.