Games and network formation