Cartoons, games, videos – screens are part of life, and the fight at switch-off time is a daily thing in many homes. It usually blows up when the end comes suddenly and nobody announced it.
School-age children understand agreements well, especially ones they helped to make. When everyone knows in advance it's two episodes or one game, switching off means keeping the deal – not a punishment.