BUFFALO, MINN. — They huddled in exam rooms and bathrooms as gunshots and explosions echoed around them. Knowing a man with a gun was loose in the Allina Health Buffalo Clinic, they saw death coming for them.

"I knew I was going to die and never see my family again," sobbed Jessica Stageberg a nurse practitioner at the clinic. Lying on the floor behind a toilet in a locked bathroom, she heard footsteps in the hallway and a man's voice trying to coax her out of hiding.

"I thought he was coming back with a larger gun," she said.

Stageberg was among a half-dozen clinic workers and patients who testified Wednesday in Wright County District Court about the events of Feb. 9, 2021. Gregory Ulrich is charged with premeditated first-degree murder and a host of other crimes in the attack, which left four people wounded and medical assistant Lindsay Overbay dead of a gunshot wound in the stomach.

Tony McAlpine had come to the primary care clinic that cold winter morning for a routine checkup. Waiting in an exam room, he heard several sharp noises.

"It kinda started to set in a little bit that it was probably gunfire," he testified. Peering out of the room, he saw a woman lying on the floor. He raced to the front of the building, searching for help, then retreated when he caught a glimpse of the gunman in the lobby.

Moving toward the back of the clinic, he knelt by Overbay and rolled her over, seeing the wound in her belly.

"She didn't look good," he said. Police arrived about then, subdued the gunman — identified by many witnesses as Ulrich — and escorted McAlpine and others from the building.

Asked what was going through his head during those frantic minutes, McAlpine replied, "Just kind of disbelief that this was going on. Just in kind of a daze."

Kristine Teesdale was in to have a couple of broken toes looked at. She was pulling off her sock in an exam room when the first shots rang out.

Teesdale saw a woman who had been shot in the arm and was lying in the hallway. She pulled the wounded victim into the exam room, took her sweater off and bound it around the woman's arm as a tourniquet.

"She was saying, 'Help me, I don't want to die,'" Teesdale testified. "I was trying to comfort her.

"It's all just a big blur."

Testimony is expected to continue Thursday and Friday with experts from the Minnesota Bureau of Criminal Apprehension who will present scientific evidence on gunshots, explosives and other technical aspects of the case.