"It was about 30 or 40 minutes into the class when I heard a couple of shots fired, I couldn't hear anything when he had walked in because my ears where ringing so badly," the 18-year-old student, Mathew Downing, said in a statement released Friday.
The gunman ordered everyone to get into the center of the room and to be quiet, and he put a backpack on the front desk and pulled out an envelope that he said contained a flash drive, Downing said.
"He looked directly at me and said hey kid with the glasses you are the lucky one, I will not shoot you if you give this to the cops," Downing said in the statement.
"I stood up and he pointed the gun at me and this is the moment I thought I was going to die," Downing said. "He paused for a second and then handed the envelope to me and said to sit in the very back seat and face him."
Virginia Tech in Blacksburg, Virginia -- 33 killed (including shooter), 23 injured on April 16, 2007
A Virginia Tech student stands by a cardboard "VT" that was part of a makeshift vigil placed on a drill field at Virginia Tech early Tuesday, April 17, 2007, in Blacksburg, Va., to honor the victims of the shootings on the campus Monday. (AP Photo/Casey Templeton)
Sandy Hook Elementary in Newtown, Connecticut -- 28 killed (including shooter), 2 injured on December 14, 2012
Residents grieve following a shooting December 14, 2012 at Sandy Hook Elementary School on December 14, 2012 in Newtown, Connecticut. At least 26 people, including 20 young children, were killed when a gunman assaulted the school and another body was found dead at a second linked crime scene, police said. Police spokesman Lieutenant Paul Vance told reporters that the attacker killed 20 children and six adults, including someone that he lived with, at the Sandy Hook Elementary School in Newtown, Connecticut. The gunman also died at the scene, and a 28th body was found elsewhere. AFP PHOTO / Don EMMERT (Photo credit should read DON EMMERT/AFP/Getty Images)
University of Texas in Austin, Texas -- 16 killed (including shooter), 32 injured on August 1, 1966
Police officer Ramiro Martinez (left) at a press conference after he and other officers shot student Charles Whitman (1941 - 1966) dead after Whitman went on a shooting spree at the University of Texas at Austin, 1st August 1966, killing 15 and wounding 31. (Photo by Shel Hershorn/Hulton Archive/Getty Images)
Columbine High School in Columbine, Colorado -- 15 killed (including gunmen), 24 injured on April 20, 1999
Police officers gather in front of Columbine High School, in Littleton, CO, before searching the building to insure that it was secure 20 April 1999, following a shooting spree by two masked teenagers. As many as 25 students were killed when two gunmen opened fire on students inside the school building, before turning their weapons on themselves in the rampage. AFP Photo by Mark LEFFINGWELL (Photo credit should read MARK LEFFINGWELL/AFP/Getty Images)
Umpqua Community College in Roseburg, Oregon -- 10 killed (including shooter), 9 injured on October 1, 2015
Led by chaplain Toni New, a chaplain for the Billy Graham rapid response team, friends of the late Rebecka Ann Carnes, one of the Umpqua community college shooting victims, embrace each other for an emotional prayer at a memorial service in Winston, Ore., on Oct. 3, 2015. (Marcus Yam / Los Angeles Times via Getty Images)
Red Lake High School in Red Lake, Minnesota -- 10 killed (including shooter), 5 injured on Marck 21, 2005
This Red Lake Net News internet webpage photo captured 22 March, 2005 shows people and emergency vehicles outside of the Red Lake Senior High School in Red Lake, Minnesota. A teenage student went on a shooting rampage at an Indian reservation 21 March, killing his grandparents at their home and then seven people at his school, grinning and waving as he fired, authorities and witnesses said. The suspect apparently killed himself after exchanging gunfire with police. The shooting is the worst US school massacre since Columbine in 1999, police and local media said 22 March. AFP PHOTO/DSK (Photo credit should read DSK/AFP/Getty Images)
Oikos University in Oakland, California -- 7 killed, 3 injured on April 2, 2012
Bodies of the shooting victims at Oikos University are covered with tarps on the ground as police survey the scene on April 2, 2012 in Oakland, California. According to the Oakland Police Department, the shooting suspect is believed to be in custody. (Photo by Jed Jacobsohn/Getty Images)
Isla Vista killings near University of California at Santa Barbara -- 7 killed (including gunman), 14 injuted on May 23, 2014
Two men kneel at a makeshift memorial after a killing rampage May 24, 2014 left seven people dead, in Isla Vista near Santa Barbara California May 24, 2014. Authorities said the 22-year-old lone gunman, Elliot Rodger the son of a director who worked on the 'The Hunger Games' killed six people. Rodger also died in the attack. (Photo by ROBYN BECK/AFP/Getty Images)
Stockton schoolyard at Cleveland Elementary School in Stockton, California -- 6 killed (including gunman), 32 injured on January 17, 1989
A crowd gathers around the Cleveland Elementary School in Stockton, Calif., Jan. 17, 1989, where a gunman killed five students, wounded more than thirty, then turned the gun on himself. (AP Photo/Walter J. Zeboski)
Poe Elementary School bombing in Houston, Texas -- 6 killed (including perpetrator), 19 injured on September 15, 1959
Northern Illinois University in DeKalb, Illinois -- 6 killed (including shooter), 17 injured on February 14, 2008
A victim is moved shortly after the shootings on the Northern Illinois University campus Thursday, Feb. 14, 2008, in DeKalb, Ill. A gunman, identified by police as Stephen Kazmierczak, killed five people before killing himself. (AP Photo/Northern Star, Stacey Huffstutler)
Westside Middle School shooting in Jonesboro, Arkansas -- 5 killed, 10 injured on March 24, 1998
Unidentified family members adjust flowers at the grave site of Shannon Wright, Sunday, March 29, 1998, in Jonesboro, Ark., the day after she was buried. Wright, a teacher, and four students were shot to death by two students at Westside Middle School, Tuesday. Pastors urged forgiveness Sunday and praised the hundreds of behind-the-scenes helpers who have given their time, talents and treasures after a deadly school shooting shattered the morale of many in this community. (AP Photo/J. Pat Carter)
West Nickel Mines School in Nickel Mines, Pennsylvania -- 6 killed (including gunman), 5 injured on October 2, 2006
A helicopter takes off from the West Nickel Mines Amish School, in which a gunman killed five girls and injured five more, in Nickel Mines, Pa., Oct. 2, 2006. From the moment a gunman began shooting 10 girls in the now-demolished schoolhouse Oct. 2, 2006, two and a half agonizing minutes ticked by before state police were able to force their way into the barricaded building, according to newly revealed details about the siege. The Pennsylvania state trooper in command at the standoff says an important lesson was learned by that delayed entry and reinforced in April by the Virginia Tech massacre: The nation's front-line police officers need better training and more equipment to deal with barricaded gunmen holding hostages, including battering rams and forced-entry tools.(AP Photo/Matt Rourke)
Santa Monica shooting in Santa Monica, California -- 6 killed (including gunman), 2 injured on June 7, 2013
Investigators look around near the scene of two shooting fatalities and a possible suspicious package after multiple shootings took place at various locations including Santa Monica College June 7, 2013 in Santa Monica, California. According to reports, at least six people have died in the shootings. (Photo by David McNew/Getty Images)
Thurston High School in Springfield, Oregon -- 4 killed (2 elsewhere), 25 injured on May 20-21, 1998
A police officer walks past the entrance of Thurston High School 22 May as the investigation continues following a fatal shooting the previous day. Fifteen-year-old Kipland Philipp Kinkel killed two fellow students and injured twenty-three others 21 May after he entered the school's cafeteria with a semi-automatic rifle and two hand-guns. AFP PHOTO Hector MATA (Photo credit should read HECTOR MATA/AFP/Getty Images)
Marysville Philchuck High School in Marysville, Washington -- 5 killed (including shooter), 3 injured on October 24, 2014
A student wearing a Marysville Pilchuck football jersey is comforted at a church Friday, Oct. 24, 2014, where students were taken to reunite with parents following a shooting at Marysville Pilchuck High School in Marysville, Wash. (AP Photo/Ted S. Warren)
"The shooter ... asked one of the other students to stand up and when he did asked him if he was religious. The student said he was Christian and was shot," Downing said.
"He then had another student stand up and asked him the same, when he answered Catholic the shooter then asked if he believed in the afterlife. The student said I don't know and the shooter thanked him for standing up for his beliefs and shot him."
A woman on the floor "said she was sorry for whatever happened to him and for whatever she had done wrong," according to Downing. "The shooter then said that he bets she was and shot her," Downing wrote.
"I stood up and he pointed the gun at me and this is the moment I thought I was going to die."
Mathew Downing, survivor of the Oregon shooting
Harper-Mercer reloaded his two handguns from ammunition in the backpack, Downing said. Police arrived and the gunman "leaned about half of his torso out of the classroom to fire on the police."
"The shooter leaned out of the classroom about two times and was shot by one of the officers then retreated into the class," Downing said. "When this happened, he laid down on the ground and shot himself in the head."
President Barack Obama traveled to Roseburg Friday to meet with the families and surviving victims of the mass shooting.
Downing said he wrote his account of the shooting in order to "get my story out in a way that I feel comfortable."
"The final thing I want to add is that I and everybody else should get from this is that any day could be your last," Downing said in the statement.
"You don't want anybody's last memory of you to be a bad one so everybody needs to take it upon themselves to just be a lot nicer to people," he said.
WATCH: Meet the first responders who came face-to-face with a mass killer: