import java.applet.Applet; import java.awt.*; import java.awt.event.*; public class FlyApplet extends Applet implements ActionListener { public Button b1; public int stim_x; public int stim_y; public Fly fly; public void init() { stim_x = 100; stim_y = 300; b1 = new Button("Create"); b1.addActionListener(this); add(b1); fly = new Fly( this , new Network( this )); } public void actionPerformed(ActionEvent e) { fly.start(); } }