I have the appropriate code,
applet.removeMouseListener(blah); applet.removeMouseMotionListener(blah); applet.removeKeyListener(blah); applet.addMouseListener(newBlah); applet.addMouseMotionListener(newBlah); applet.addKeyListener(newBlah);
I am writing the game in Eclipse and when I run it as an applet from inside eclipse, it works perfectly, one controller is replaced with another one as the game state changes.
When I create my own html file:
<HTML> <HEAD><TITLE>Zone Control Game</TITLE></HEAD> <BODY BGCOLOR=#000000> <APPLET CODE=game.GameApplet.class WIDTH="400" HEIGHT="300"> </APPLET> </HTML>
and run it (both in IE and firefox) the controller switching doesn't take place like it should. It just sticks with the first controller I give it, MenuController and doesn't switch.
I know the <applet> tag is suppose deprecated, but I hate messing with object tags. Is this my problem or is there something else I should know about applets?
This doesn't seem to make sense because Eclipse just creates its only own html file, using the applet tag, and runs a mini browser on it and it works fine.












