Scattered around Ed Minasian’s feet were copies of Bat Girl, Wonder Woman and Spider-Man — just a few of the comics he had snatched from boxes haphazardly spread throughout the San Francisco library donation center in Potrero Hill.

After examining each one, he’d glance at a printed spreadsheet to check and see which comics he already owned.

“I’ve been a collector since I was a little kid,” the 50-year-old San Jose resident said.

Minasian was one of the dozens of comic lovers who lined up outside the donation center at 10 a.m. for Saturday’s Friends of the San Francisco Public Library’s comic book sale, with proceeds going to the library.

For those like Minasian, the event was a collector’s dream, a chance to search for the missing book that would complete a series. And at 25 cents per book, most considered the opportunity a steal.

For the less earnest collectors, like 24-year-old June Park, the book sale was a chance to peruse tens of thousands of comic books for inspiration.

The San Francisco resident stood toward the back of the center, thumbing through Marvel’s Civil War II: Kingpin.

Park, a sketch artist, said her main interest was Japanese anime, but she had come to snag books that would influence her art.

“I think I’m picking them out on a design and arts point of view,” Park said, patting the 10 or so comics she had set aside for purchase.

In front of her, people were standing shoulder-to-shoulder, frantically rifling through the boxes of unsorted comics in silence.

Some had filled empty boxes with comics to take home with them.

Alan Bernstein, a 24-year-old San Francisco resident, lugged his box of chosen comics throughout the row of tables as he searched for more.

He said when he first arrived, he heard that one person’s box of books had been stolen. Bernstein kept his box close, placing his hand on it whenever another person came close to touching it.

Nearby, one child had escaped the herd of excited people by sitting under the tables of books with a comic in hand. Other children were sprawled on the floor, looking at the books their parents had picked out.

Brenda Salguero, the manager of volunteer services for the book sale, said it wasn’t long ago that serious literature readers turned up their noses at comic books.

But Salguero, a comic book fan herself, said comics are the perfect “gateway to reading.”

Comics aren’t just about fighting bad guys and pictures, she said. They also addresses social issues, including gay marriage and diversity.

“It’s been very amazing and inspiring to see better representation of people of color,” Salguero said.

From Marvel’s Muslim Pakistani American superhero, Dust, who debuted in 2014, to the upcoming movie release of Black Panther in February 2018, Salguero said she “really appreciates” Marvel’s commitment to bring diverse stories to the forefront.

As the hours ticked by at the donation center, the energy to search for more books hadn’t dwindled. Minasian had filled his black tote bag, which had “Comics Conspiracy” and Batman’s mask printed on the front.

But he was going back for more, though he said his wife would groan at the sight of more comic books, which included a copy of Superman vs. Muhammad Ali and two copies of Harley Quinn.

“I’ll get in trouble when I get home,” Minasian said, who works in corporate finance. “It’s my little pastime to get out of the grind of Silicon Valley.”

Sarah Ravani is a San Francisco Chronicle staff writer. Email: sravani@sfchronicle.com Twitter: @SarRavani