Learning equilibria of games via payoff queries