I'm sure like Lucas, Mel will likely have input and say, even pitch ideas and dialogue. Nobody in their right mind is going to ignore him if they are fans. Further more, they probably have ideas and dialogue that Mel has been chewing over his his min and to paper for decades; he's been trying to get this thing made for years and back in the day he probably thought there was going to be a sequel, so he probably started writing things down.
Sometimes comedy films, like TV series, maybe one one or two credited writers, but there is a collaborative approach, lines pitched, actors ad libbing, etc.