(Image Credit: ABC)

ABC News' John Schriffen reports:

A hostage situation ended peacefully after a gunman walked into a sporting goods store in Yuba City, Calif., and held a female employee at gunpoint for hours, officials said.

The suspect, identified as Juan Carlos Alvarez, 29, eventually surrendered to police on Sunday in what authorities believe was a botched robbery inside a Big 5 Sporting Goods store. The hostage, Allyson Taylor, 18, was able to escape the harrowing incident without injury thanks to some quick thinking on her feet.

Cops say that Taylor opened up a dialogue with her captor, which eventually led to a peaceful end to the standoff. "She knew when to push, she knew when to let him be. You can't help but thank her enough and be in awe of that young girl," said Shawna Pavey, operations support manager of the Yuba City Police Department.

"He didn't want to die that day. He wanted to be able to see his daughter again and so I knew that… as long as, 'You don't hurt me you can see your daughter again,'" Taylor said.

The incident began just after 11 a.m. when Taylor was greeting customers at the door and was the first to encounter the suspect.

"He lifted up his shirt, pulled the gun out, I believe the back of his pants, and immediately pointed at me," Taylor said. "I just freaked out and then he raised the gun and let out a shot to the ceiling."

As the alleged gunman screamed at customers to leave the store, the manager stood behind and dialed 911.

"I have a gun shot in the store. I need an officer here now," the store manager told the 911 operator.

"At Big 5?" he operator asked.

"Yes. I'm hiding under the desk in the office," the manager said.

Across the store was 23-year-old employee Matthew Rasul, who had just returned from a break when the incident began.

"I was just in the dark, there is nothing worse than not knowing because I always assumed the worst was going on, and that is the scariest thing," Rasul said.

Rasul was able to relay minute-by-minute updates to the police over the phone.

"I see my manager and one of our part-time workers with their hands up. I'm not going to go let myself be seen," Rasul told 911.

"Oh no, no, no, I'm not telling you to go out there? What is it that he said?" asked the operator.

"Nothing he said 'Come over here' and then he has one of our part-time workers," Rasul replied.

It was around this time that, Taylor says, that Alvarez grabbed her by the neck and dragged her into the office where the store's safe was located. Taylor told him that she didn't know how to access the safe, but Alvarez told her he didn't want money.

Taylor sat with Alvarez for the next four hours, never explaining what he wanted.

"I knew in my mind that it would be easier for him to shoot me if I didn't look him in the eye or if I didn't talk to him, make a connection with him," Taylor said.

But Taylor did speak with the suspect and began to reason with him about seeing his daughter. Taylor's soothing tone, coupled with calls from hostage negotiators, finally convinced Alvarez to surrender to police outside the store around 3 p.m.

"I just started shaking, I could barely walk out of the store," Taylor said. "But once I was in the hands of the police officers, I knew at that point I was fine and OK."