Hasbro (NASDAQ:HAS) romped all over second-quarter earnings expectations, delivering sales and profits well ahead of analyst forecasts. Driven by the megablockbuster Avengers: Endgame movie and the toymaker's new digital game Magic: The Gathering, Hasbro posted results that are bad only in the sense that it's given itself a very high hurdle to get over next year.

Players at a Magic: The Gathering tournament

Magic: The Gathering still has a lot of power to enthrall players, whether it's the physical game or the new digital version. Image source: Wizards of the Coast.

Big-screen bonanza

Revenue jumped 9% to $985 million in the period, easily surpassing the 6% gain Wall Street forecast, and when you back out foreign currency exchange rates, sales were actually 11% higher.

In large part that was because of the massively successful Avengers movie, which went on to become the highest-grossing film ever, surpassing the record set by Avatar. The finale to the superhero series that spanned a decade has generated almost $2.8 billion in worldwide box-office receipts.

Hasbro hinted back in the first quarter that toys surrounding the franchise were selling well, which should have given the movie's producers an inkling to how it would be received at the box office. Likewise, investors should have been clued in that it would drive Hasbro's top and bottom line, as the movie kept breaking records.

Investors may want to keep this in mind for next quarter, as Hasbro says Spider-Man: Far From Home also contributed to revenue growth this quarter; while it won't be an Avengers-type blockbuster, the movie is already approaching the $1 billion global box-office mark, and it was only released on July 2.

But Hasbro's fortunes have been impacted by movies ever since it started meshing its toys with them, beginning with Transformers. Notably, that franchise is still paying dividends, and the toymaker is looking forward to the brand delivering good results for the full year -- and next year, when it and Netflix launch the Transformers: War for Cybertron animated movie trilogy.

Successful transition to digital from analog

While these big-screen films garner a lot of headlines, a deeper, more compelling power playing behind the scenes is Hasbro's card game Magic: The Gathering, particularly in its digital version.

Similar in theme to the better-known Dungeons & Dragons role-playing game, Magic has been casting a spell over players for more than two decades. Yet as video games have migrated to the online sphere, Hasbro realized it needed Magic to evolve as well, and last year began transforming it into a digital property.

That's paying off in a big way: Hasbro's entertainment, licensing, and digital segment saw revenues surge 28% year over year to $96 million, mostly due to Magic: The Gathering Arena, Hasbro's online play portal for the game (not to be confused with MTG Online, which was essentially just the tabletop version digitized without the fancy graphics).

Although operating profit for the segment declined in the quarter, that's only because of the amount of money Hasbro is investing in Magic and the costs associated with bringing it online.

The player community has responded to the porting of the game online, with approximately 400 million games played in the quarter and 1.1 billion played since the digital version was launched last September. Moreover, Hasbro is enmeshing it into the growing esports phenomenon, hosting the Mythic Championship on the Arena platform in June, with dozens of the top Magic players competing for a share of a $750,000 prize pool.

Hasbro had a number of other successful properties this quarter, too, but these were the leading lights this time around. A full lineup of other growth drivers remains for the rest of this year, and into the next, which suggests the toymaker's blowout second quarter might not be its last.