Memory and Analogy in Game-Playing Agents