I recall them saying that BOTW needed to sell 2 million copies to break even: https://www.forbes.com/sites/olliebarder/2016/06/30/zelda-breath-of-the-wild-needs-to-sell-2-million-copies-to-break-even/?sh=2a751ec1615f
Hahah! This is why Nintendo is awesome. They budget games so that they would be profitable even on a dud system like the Wii U. And on a really successful system, like the Switch, they make crazy profits.
Of course, the real profit making potential on a game like BotW is it's ability to sell hardware. The biggest profits come from multiplication and not addition. Calculate the profits on 20m copies of BotW and that is thinking in "addition" terms. But a bigger install base increases the sales of every new game that is released. That is thinking in "multiplication" terms. Also a bigger install base means more titles will come to the system. That is also multiplication. On a system like the Switch, it's profitable even if you only count revenue from third party royalties. And then when you also count first party sales, hardware sales, subscriptions, etc... then it's ridiculously profitable.
The real measure of a first party game is not if it generated a profit. The real measure is in how well it moves hardware. Profits on a single game is money addition. Having a bigger install base is money multiplication. So Nintendo probably broke even or made a minor profit on systems like the Gamecube or Wii U, but they are still duds, because their games didn't move hardware. Why break even when you can make mad, stupid profits? This is the idea of opportunity cost. Nintendo wastes time and money when they make games that don't move hardware. Games that move hardware are a good investment.
So if a game makes a profit, that alone doesn't make it a good candidate for a sequel. Almost every Nintendo published game makes a profit. But there is still a big difference between a system like the Switch and a system like the Wii U. They need to make games that move hardware so they keep having Switch-like sales instead of Wii U-like sales.