It's a far too overly talked about story, but Ant-Man is the "bastard step-child" of the Marvel Cinematic Universe. Having had its original director, Edgar Wright (and the lone reason I had any interest in the film) walk away and then have the entire movie basically overhauled to fit better into the unified vision of the other Marvel films in "Phase 3" definitely didn't do it any favors in that regard.
For a time though, there was a sliver of hope that Adam McKay might take over for Edgar Wright. It didn't happen, but he did volunteer to re-write the script and did so with his former Anchorman star Paul Rudd.
McKay spoke a bit with Collider on the topic and his initial apprehension:
[Rudd] called me when Edgar Wright stepped away from the project and told me what was going on. I went and met with Marvel, and I was a little dubious just because I’m friends with Edgar and I didn’t know what the story was, and then when I kind of heard what happened, that Edgar had parted ways, and then I saw their materials, I was like, ‘God this is pretty cool’. Ultimately I didn’t want to jump in as a director, I had too many other projects going and it was too tight, but I thought, ‘You know what, I can rewrite this, and I can do a lot of good by rewriting it.’McKay then spoke to collaborating with Rudd:
I’ve always known Paul Rudd’s a really good writer from improvising with him on set, but I had no idea he was that good—he’s really great with dialogue. So the two of us holed up in hotel rooms on the east and west coast, and I think it was like six to eight weeks we just ground it out and did a giant rewrite of the script. I was really proud of what we did, I really thought we put some amazing stuff in there and built on an already strong script from Edgar Wright and sort of just enhanced some stuff.