"that was just an act to get a ride"
(1) 'Act'
When people pretend to do something, they are putting on an 'act'.
An 'act' is a pretence or false display. It is behaviour or actions that are not genuine.
Example: My friend kept saying how much he loved cats, but his words and behaviour was all a pretence. They weren't true. He was putting on an 'act' because in fact he didn't like cats at all.
(2) 'to get a ride' usually just means you are getting someone to provide you with a favour - to drive you somewhere.
But, in your text the meaning is slightly different. When he wants 'to get a ride', the context is saying he wants to accompany her. His main reason is to be WITH her, or to go with her. If she wasn't going, he would have no interest.
Putting it all together, "that was just an act to get a ride" means the boyfriend's behaviour was a pretence/not genuine, so that he could go with (accompany) her.
There's not enough text to know if they actually went to London, but it sounds like they didn't - or at least, not yet.