Scientists think they’ve found a drug that can help rats shake off behaviors associated with compulsive gambling – suggesting a possible treatment for people that fall under the spell of the one-armed bandit.

As described in a paper published earlier this month in the journal Biological Psychiatry, University of British Columbia scientist Paul Cocker and his colleagues built a casino simulation and trained the rats to become inveterate gamblers. (Sadly, the tiny rat casino had neither rat cocktail waitresses nor a tiny buffet table).

Training the rats to gamble was actually not that hard, according to Cocker.

“Animals are fantastic at recognizing when a reward is available,” Cocker said in a phone interview.

In the rat casino’s version of a slot machine, an animal was put into a box equipped with two levers, and three flashing lights set in little holes just big enough for a rat to poke his nose into. When a rat presses the “roll” lever, the first light flashes until the rat pokes his nose inside the port, which stops the light in either the on or the off position, and sets the second light flashing. The rat then repeats the nose-poke routine twice more. If all three lights are lit up, a rat can press the second “cash out” lever and get 10 sugar pellets as a reward. But if the rat pressed the cash out lever on a losing trial, it got a 10-second time out before it could try again.

To maximize their sugar pellet reward, the rats should have chosen the “roll” lever on all trials except for the winning ones. Cocker and his team found that the rats were more likely to erroneously press the “cash out” lever when two out of the three lights were lit up – a “near miss” – than when just one or no lights lit up.

The allure of the near miss “is the main reason slot machines are thought to be so addictive,” Cocker says. A lot of slot machines will give you two matching items, but the third slot will fall just short of the right picture to pay out. This scenario “has been reliably shown to galvanize gameplay and keep people spending money.”

If there were some way to block the allure of the “near-miss,” that could go a long way to curtailing compulsive gambling behavior, the researchers thought.

Cocker and colleagues found that by administering a drug that blocks the D4 dopamine receptor in the brain, the rats made fewer “near miss” errors. Interfering with this particular reward pathway seems to make rats better at distinguishing between clear wins from near-wins.

We can only infer what’s going on inside the rats brains, Cocker says, but it would seem as though that when one of those near-miss rolls occurs, the rodents think “hey, I might get rewarded!” But with the drugs, the rats “seem less susceptible to that reward,” Cocker says.

It’s not exactly a perfect analogy to human gambling, but a promising find nonetheless. Getting less of a thrill from a near-win may help dull the urge to keep gambling. Plus, the drug in question was tried out as a possible anti-psychotic medication in the 1990s, but seemed to have no effect on schizophrenia. But the fact that the drug made it all the way to human trials suggests that it could be well-tolerated in people. The next thing to do would be to try the drug out in a population of healthy people, and then in a population of compulsive gamblers.

“Whether we’re the right group to do that or if someone else wants to roll with it, we’ll see,” Cocker says.