A former Utah library director who pled guilty to stealing $89,000 from the library where he worked to purchase items in “Game of War” was sentenced to 30 days in jail, community service and ordered to pay most of the stolen cash.

On Tuesday Adam Winger pled guilty to theft and forgery during an appearance at the Utah First District Court on Tuesday. The 38-year-old stole North Logan City credit cards meant for funding the public library’s expenses to purchase hundreds of gift cards for himself, according to police. He then used the gift cards to purchase items in “Game of War.”

“Game of War’ is a popular mobile phone game based on a “freemium” subscription model from developer MZ. It was one of the top-grossing apps of 2014 and 2015 and has since enjoyed success as players sink time and money into its expansive PvP battles and resource-gathering gameplay.

Its aggressive in-game marketing is geared toward players spending cash on purchasing materials, power-ups, and upgrades as well as in-game gold packs that cost anywhere from $5 to $100.