In writer-director David Ayer's End of Watch, Chicago-born Michael Peña plays Mike Zavala, a young officer in the Los Angeles Police Department patrolling South Central LA with partner Brian Taylor (Jake Gyllenhaal). He talks about making the thriller with Ayer and Gyllenhaal.

Did your opinion of the LAPD change at all making End of Watch?
Michael Peña:
I'm going to be honest – it changed quite a bit. I grew up in a neighbourhood where we were socially conditioned to think that the cops were bad. In retrospect, why would I think that? I took my advice from a bunch of criminals. But while making End of Watch, we did 30, 40 ride-alongs with real cops and got to see the real deal. They actually get p***** off when somebody steals from a shop-owner, or from someone coming home from church or work, or from kids playing basketball. They actually get mad at the ethics of crime. Most people only think about police officers when they're driving, 'Oh, is my registration up to date? Have I got my insurance?' But these guys really care about the people on their beat; they think about the neighbourhood. They want to keep the criminals out and preserve the goodness for the people. I never really got that before I made this movie.

What kind of involvement did the LAPD have with the production?
David Ayer had so many hook-ups. We trained with LAPD SWAT. I personally loved this script and I loved this project and I was scared about it because the dialogue read like a David Mamet play. We had to rehearse for five months; there was no other way to do it. Everything was hard-hitting, and we had to train the same way. We had to be able to pull out the gun, reload it, put it back down, walk and talk on the walkie-talkie while we were doing it and still keeping this whole brotherhood idea that's ever so important in any law enforcement situation. That's what I really got from the movie and that's what we tried to instil. We realised that it was going to live or die based on that.

Working so closely with another actor, as you did with Jake, you undoubtedly got close but did you ever get on each other's nerves?
We definitely got on each other's nerves. My hat goes off to him – he's a great guy. To be honest, I hold up a little bit more of a fence and he's open and he really helped me out a lot when we were trying to do things. My dad was in the military, my brother's a correction officer and I'm not the most open dude. So he helped me a lot with that.

You shot in South Central LA neighbourhoods. What was that like?
We had bullet-proof vests on all the time. Cops get shot at all the time in South Central so somebody doing a movie about cops? They're not gonna care. What was weird though was seeing the paparazzi because they follow Jake anywhere. That was so odd. Paparazzi are insane in LA; they just don't give a rat's ass! There's a bunch of gangsters and then you'll see a long lens through the gangsters: 'Can you move to the right, please?... Jake! Jake! Jake! Love you, Jake!' They'll do anything for a shot! They actually started paying people a hundred bucks so they could be on their roof if they knew we were going to be shooting.

What was David Ayer like as a director and what does he do well?
First and foremost, I think he's a writer but he's a very visual writer. When I first read the script, I didn't know why it was good. I just thought, 'Dude, I've got to be in this movie, please God let me be in this movie'. When I read it at home, it was like finding your new favourite book and thinking, 'It would be so good to be in it'. So I met with David and his knowledge is so full that the script is literally just vines from the major root. If an actor is really willing to listen to the guy and pay attention to what he's saying, their character would be infinitely more textured. We had five months of that, thank God. He just gives you the icing but then instead of just getting the cake, you're also getting a steak.

What kind of direction did he give you once you were on set?
He would give me a little direction here and there but the best thing was that he would say, 'You know the character better than I do, man. Show me what's up'. And then he would literally challenge us. Because we'd done all this weapons training, all this mixed martial arts training. It's one thing that I'm going to take away is that we had the best time shooting. He'd be like, 'Show me something good, dude, show me something good'. And I just gave it my all.

End of Watch is in cinemas from Friday November 23.