FORSYTH, Mo. (AP) _ A generator fire poured thick smoke into a county jail before dawn Saturday, killing four of the 26 prisoners who were trapped in their cells behind electronically powered doors.

Firefighters donned air masks and used a special tool to open each cell. All the surviving prisoners were treated for smoke inhalation, and 13 were hospitalized.

''You couldn't send anybody in without air bottles,'' Fire Chief Ron Correll said. ''It was unreal.''

The four prisoners who died - three men and a woman - were jailed in cells near the generator, Correll said.

Nearly 100 firefighters were sent to the fire in Forsyth, in far southwestern Missouri, about 35 miles south of Springfield. Eleven firefighters and a jail dispatcher were treated for smoke inhalation.

The fire apparently started in an auxiliary generator next to the one-story Taney County Jail, Sheriff Chuck Keithley said. The blaze knocked out electricity to the jail.

''We have a lever that fits into the lock and you have to crank it open, and we did that individually with each cell,'' said sheriff's investigator Dick Ringler said. ''Our maximum-security area was the toughest to get in. We had to use a cutting torch on that.''

Firefighter Kevin Clayton said that when he arrived at the jail, ''the generator was on fire, the roof was on fire, the jail was full of smoke. Inside, you couldn't see your hand in front of your face.

The inmates were shouting ''Help 3/8 Help 3/8'' and ''hollering to get out,'' he said.

''I was just about passed out when they finally got my door open,'' inmate Ronald Hankins said from the jail in nearby Branson, where he was taken after being treated for smoke inhalation. ''You couldn't see nothing. You couldn't see the bars, you couldn't see where you were at.

''People were screaming and hollering. It was awful,'' Hankins said. ''Then it got quiet because a lot of people passed out. I just know it was real scary. I knew I was going to die.''

Firefighters instructed the inmates to cover their faces with water-soaked towels and lie on the floor until they could be freed, Clayton said.

Rescuers had to carry each inmate out of the jail. Emergency workers set up a makeshift clinic on the courthouse lawn, treating victims before they were taken to regional hospitals.

''We had bodies lying everywhere,'' the fire chief said.

The fire began at 3:45 a.m. when an extension cord connected to a battery charger on the auxiliary generator short-circuited, said Bill Zieres, regional chief fire marshal investigator. The extension cord ran up the side of the jail, inside and then ran the length of the jail, he said.

The short circuit was responsible for knocking out power to the jail, Zieres said. The short began a fire in the metal and wood shed housing the generator, and the fire fed on a propane tank situated nearby, Zieres said.

The flames then spread to the graveled roof of the jail. Apparently, some wood supports in the roof and some insulation also burned, producing a thick smoke, Zieres said.

''We don't know why it shorted out. We just have evidence there was a short,'' Zieres said during an afternoon news conference.

The generator and use of the extension cord didn't violate any fire code regulations, Zieres said. He didn't know why the propane gas tank was so close to the generator.

The dispatcher on duty, Jerry Newman, radioed for help before his system went out. Newman was treated for smoke inhalation and released.

The generator had not had any ''serious problems'' before the fire, Keithley said. He was unsure when it was checked last and whether any repairs had been made.

The jail was built in 1981 and designed to hold 40 prisoners, he said. County offices occupy a lower level. Seven prisoners were in satisfactory condition at Skaggs Community Hospital in nearby Branson. Three were in serious condition at Cox Medical Center in Springfield, and three were at St. John's Regional Medical Center in Springfield, where hospital officials refused to release any information.

The victims were identified as Robert Wilder, 39, held for about a year on a murder charge; Donna Redhan, 58, held on a charge of driving while intoxicated; Charles Lee Nagel, 37, held on charges of forgery and failure to pay child support; Michael Sean Hasson, 23, whose charges couldn't be immediately confirmed.