Get breaking news alerts and special reports. The news and stories that matter, delivered weekday mornings.

VIERNHEIM, Germany — Police shot and killed a masked gunman who took hostages in a German movie theater complex Thursday, officials said.

The drama unfolded at the Kinopolis movie complex on a sunny afternoon in the southwestern town of Viernheim.

Heavily-armed police run outside of the movie theater complex in Viernheim, Germany. Alexander Scheuber / Getty Images

Guri Blakaj, 21, works as a cashier at the cinema and told NBC News he initially thought the gunman was a customer in costume.

Let our news meet your inbox. The news and stories that matters, delivered weekday mornings. This site is protected by recaptcha

"I asked him if he wanted money and he only said we should do what he says," Blakaj explained, describing how he and his colleagues were instructed to close the front doors and lay on the floor.

"We laid on the floor and I pushed the silent alarm," Blakaj said. The gunman — who the cashier described as "confused" and carrying something resembling a rifle — then told Blakaj to go upstairs.

Eyewitness: gunman "appeared confused", wore mask + had long rifle. About 40 people in cinema at time, many kids pic.twitter.com/enRuCy5jR5 — Andy Eckardt (@ameckardt) June 23, 2016

While in the elevator on his way up, Blakaj said he heard shots.

Police special forces quickly responded to the scene, with footage from outside the theater showed heavily armed officers strapping on bulletproof vests and running towards the building as sirens blared.

Local Interior Minister Peter Beuth later told a parliamentary debate that initial reports suggested a gunman had fired several shots and taken hostages before being shot dead by police.

There were no other injuries and the hostages are all safe, police later confirmed to NBC News.

Police have not identified the suspect or a potential motive behind the incident.

Viernheim, a town of about 32,000, is about 45 miles south of Frankfurt.

Streets around the movie theater were blocked off and a police helicopter hovered in the air after the incident ended. Armed police special forces remained in position around local buildings.

Heavily armed special police forces still at back of cinema in #Viernheim, theatre being treated as "crime scene" pic.twitter.com/B4Cj7qRLQk — Andy Eckardt (@ameckardt) June 23, 2016

The cinema had several movies listed to show throughout the afternoon, including Hollywood productions like "Alice in Wonderland" and "Angry Birds."