|
|
1. Automatize the execution of the game
Hints (there could be also others way to do that):
. A thread could sleep for a while and then call a nextStep() method
of the game (that run a new iteration)
. Look in the Java APIs about how class "java.lang.Thread"
In a nutshell: a class that extends Thread is a thread
- the method run() implemented in this class does the work
- the method sleep(long millis) make the thread sleep for some
milliseconds.
- to run the thread you should call YourObject.start()
. If you have question like "What is a Thread?", ask me!
2. GUI and listener implementation
Hints:
. Look at the tutorial I sent you by mail for (key)listener
. Look at the example I sent you by e-mail for graphics
. Use java.awt.* packages (don't consider the swing ones):
The main idea behind this framework is the chinese-box (i.e
A set of boxes of graduated size, each fitting inside the next
larger one.)
-> A Frame contains panels, buttons, ...
Guys, I know this is a lot of work, and many things are new for you.
You know where to find me and, please, feel free to ask me if you need some
explanations about what written above.
However, I'm not expecting the everything is working fine in the M3, but I
expect to see that you have worked with these issues and you can understand
how to use them...
|