next up previous
Next: Evolving Agents: The Tron Up: Experimental Model Previous: Tron Agents

Java Applet

When a visitor opens the Tron web page3.2 , her browser loads and starts a Java applet. The applet (fig. 3.2) receives the GP code for an agent from our web server and uses it to play one game with the human user. The human moves by pressing the arrow keys and the agent, by evaluating its s-expression. When the game ends, the applet reports the result (win or loss) to the server, and receives a new agent for the next game. This cycle continues until the human stops playing.

Our Java Tron application consists of three modules: the Arena updates players position and direction, and their traces, updating the display; the Human Player module listens to keystrokes and changes the Human's orientation accordingly; a GP Player module computes sensor values and feeds them to a GP interpreter that evaluates an agent's s-expression. This module contacts the server over the web, receiving GP code and sending back game results.



Pablo Funes
2001-05-08