Sometimes the work you do pays off — 40 years later.

Robert Krug, a professor emeritus at the University of Texas in the department of molecular biosciences, has been working on what makes the flu virus tick and how we can fight it for most of his career.

"Influenza was really a human pathogen where we knew very little about it," he says. "We had lots of questions. I'm a scientist — we answer questions. The questions to be answered were the most interesting questions for me."

In 1978, he discovered the way the flu virus replicates itself in an early stage. His research lead to the development of a new pill for fighting the flu after you've been infected.

Xofluza was approved by the FDA on Oct. 24 to use on people 12 years and older who have had flu symptoms for less than 48 hours.

It's the first new antiviral flu treatment in 20 years, the FDA said in its press release.

Unlike Tamiflu, which also treats flu symptoms within 48 hours, Xofluza is one dose. Tamiflu is taken twice a day for five days.

Genentech, which is marketing Xofluza in the U.S., expects it will become available in a few weeks. It comes with a wholesale price of $150, but there is a coupon, and Genentech says it expects people with insurance will pay about $30 with the coupon and people without the coupon will pay $60. You can find the coupon at xofluza.com.

Another difference between Xofluza and other antiviral flu treatments comes from Krug's research about how the virus replicates itself at an early stage. Other treatments focus on a later stage and don't really stop you from spreading the virus.

"With this new drug, as soon as you take this pill, it stops the virus cold," says Krug, 79. 

In studies, researchers saw a drop not only in the virus numbers but also in shedding of the virus, which is what allows you to spread it to other people.

"I feel like I'm a father of a drug," Krug says. "It's a nice way to retire," he adds, which is something he's planning to do Dec. 31, when his grant ends.

What Krug discovered was the way that one of the 14 proteins in the flu virus replicates itself. He calls the process "cap snatching," and it's something that is relatively unusual in human viruses.

When normal cells in your body replicate, they copy a chemical sequence called a cap. When the flu virus replicates in a normal cell, it snatches the cap and changes the chemical sequence to have the flu virus in it. Cells then become used like a copier to replicate the flu virus instead of a healthy cell.

While the flu virus changes each year, the protein Krug was studying in the cap-snatching process doesn't change.

His research, which he published in 1979, seemed like a good place to start if you wanted to stop the spread of flu once someone had it. Still, at first he faced critics who didn't believe his concept of cap snatching.

"It was two or three years before it was accepted as correct," he says.

Nothing happened for decades to turn his research into a drug. "Drug companies were not interested," he says. "There wasn't an economic incentive."

If you think about it, with something like a diabetes drug, patients typically refill their prescription monthly. With an anti-flu drug, it's a one-time prescription.

Then, in 2000, avian flu happened in Asia. Now you had a virus that was very lethal, and Krug says things changed when the government started buying Tamiflu to prevent a deadly outbreak.

Since then, the U.S. has had swine flu and last year's flu outbreak. Now there's a market for anti-flu drugs, and more pharmaceutical companies are interested in testing them out.

Three years ago, Japanese company Shionogi & Co. looked back at Krug's 1979 research paper and figured out how to turn his knowledge of cap snatching into a way to develop a drug that would stop the virus from doing that.

Just because Krug is retiring doesn't mean he doesn't see the future of where flu research needs to go. The next big question, he says, is, "How can we get people who are infected with the flu this drug within 24 to 48 hours?"

UT researchers are working on fast and inexpensive flu tests that use your saliva and could be done at the pharmacy, skipping the time between the doctor's office and pharmacy, he says.