(CNN) -- How much is playing the same video game for a month worth? To an exasperated parent of an obsessed young gamer, probably not much.
But to Justin Chavvarria, it's worth a quarter of a million dollars.
The former high school pitcher earned $250,000 as winner of the "MLB 2K13" Perfect Game Challenge, a nationwide contest pitting virtual hurlers against each other in the popular baseball video game.
Chavarria, 21, of Eugene, Oregon, defeated two other players in a single-elimination tournament during festivities surrounding Tuesday's MLB All-Star Game in New York City.
The four finalists all threw perfect games in "MLB 2K13" during the qualifying month, but Chavarria and the other three were the most perfect. 2K Sports, the publisher of the game, said they verified more than 2,500 perfect games and used an algorithm to rank perfect games based on degree of difficulty and perfection.
A perfect game is one in which a winning pitcher records at least 27 consecutive outs -- a full nine innings -- without allowing a runner on base.
Chavarria said he played the game for about 30 days before finally getting a perfect game that qualified him for the playoffs.
His basic strategy, he said, was to use "the best (available) pitcher against the worst team." Chavarria got his perfect game with pitcher Kevin Slowey of the light-hitting Miami Marlins.
The real Slowey has never had a perfect game or even a no-hitter in his major league career. He is 42-35 in his sixth year in the big leagues.
Chavarria, who was a pitcher in high school and for one year in college, said having a pitcher's mentality helped him devise a game plan against the batters. He also thinks having that mind-set gave him an edge as his perfect game reached the later innings.
"Yeah, it really helped a lot, like when to throw pitches in certain counts," he told CNN in an interview. "It is a video game, so you don't have to be a star athlete or a pitcher in the MLB. It helps to have that knowledge ... to know the art of pitching."
For the tournament, Chavarria chose the Texas Rangers as his team, despite the fact he says he's a lifetime New York Yankees fan.
He said the Rangers "had a pretty strong lineup for the past couple of years and I felt comfortable with what they gave me."
"They've got guys who can hit home runs against lefties and righties," he said. "Their pitching is not bad."
After demolishing his opening-round opponent by a 9-3 score, Chavarria was matched up in the final against Brad Holland of Garland, Texas. Holland used the Oakland A's in his attempt to win the prize, but Chavarria's Rangers were too much.
"I hit a two-run home run in the first inning. That was a lot of pressure gone and I didn't have to worry about it as much (after that)," he said. Chavarria added another home run later in the game, and his pitching kept Holland's A's off balance as he won 3-1.
Chavarria, a student at the University of Oregon, said most of his winnings will go toward tuition and other related expenses. But he added, "I plan to spoil myself a little bit and my dad and some other family members."
For gamers who are thinking about trying for next year's challenge, Chavarria has a bit of advice.
"Just don't give up. I had plenty of times where I thought this was stupid and I ... (was) never going to get it," he said. "Just keep playing. I got mine in the last week. You just never know."