Game Development Reference
In-Depth Information
Figure 13.1
The MixUp game
in action.
private function mainMenu(e:MouseEvent):void {
dispatchEvent(new Event(MAIN_MENU));
Like the Title class, this screen is pretty minimal in its current
form, but it could support many other pieces of information or
options. Because GameHistory objects are added to the beginning
of the Array in the MixUp class, to get the latest object, the Results
class simply looks at the first element.
At this point, we at last have a game that can be played start to
finish and has multiple screens. If you publish the SWF and test it,
you will see how the game works, as in Figure 13.1 .
Before we end this chapter, however, we have one more class to
look at. It is an alternative class to use for the ISourceImage imple-
mentation. It is called SourceImageCamera, and it will use a live
feed for the grid instead. If you don
t have any kind of webcam,
then you can either skip to the next chapter or you can read on for
The SourceImageCamera Class
Our previous implementation, the SourceImageEmbedded class,
was simply a generic object. It only ran code when it was requested
and was silent the rest of the time. For this next example, we
Search Nedrilad ::

Custom Search