At first Grubb was being considered to write the screenplay himself, but the studio wanted to hire someone with experience writing for films. James Agee was hired as the screenwriter because he was from the South and had experience writing about the Depression. Agee began writing in April 1954, and finished in June, but his script was 293 pages: much too long for a feature film. Laughton made significant rewrites to the script, and his was the version used for shooting, even though he insisted that Agee be credited as the only writer. Agee's original script ended with a shot of children's faces floating among the stars, an idea that was eventually moved to the opening of the film. Throughout 1954, Gregory worked with the Production Code Administration to change the script to meet the guidelines of the Production Code. There was much concern about depicting a preacher on screen as an evil person, and Gregory made an effort to make the character of the Reverend not appear to be a real, ordained minister. Eventually the script was approved, but Protestant groups who had read the script continued to object to the film's production.