Overview Class
Flash
ActionScript 2.0

Class Three

All Implemented Interfaces:
        Serializable, MovieClip

Author:
        Jack Wootton


public class Three
extends foo implements Serializable, MovieClip


A factory class for the game itself . This class deals with all decisions and rendering for the game .
Primarily it allocates control between smaller more specific classes that make up the game .
It also initliases all resources required for game-play and in-game menus .



Constructor Summary
Three()
Field Summary
public void
age5        
public void
age4        
public Number
age2        
public Number
age1        
Method Summary
Void
func1(w:Number, h:Number)
Void
setTimer(b:boolean)
boolean
processKey(keyCode:Number, GameActionKey:Number)
Event Summary
void
onMouseClick(void)
void
onKeyPress()

Constructor Detail

Three

public Three()

Empty constructor since initialisation is performed by initGame .

Parameters:



Field Detail

age5

public static age5 : void

age4

public static age4 : void

age2

public static age2 : Number

age1

public static age1 : Number


Method Detail

func1

public func1(w:Number, h:Number):Void

Used to set all data members to their default values . Specifically display dimensions are used to further initialise other classes such as Player , TheOthers , WeaponsShop , World , TaskHut , Onventorym Inn , Stats , GraphicalTimer and all data required to play Island Adventure .

Parameters:
        w - Width of the hardware device ' s deisplay
        h - Height of the hardware device ' s display

Returns:
        Void -

See also:
        AnotherClass1
        AnotherClass2
        AnotherClass3


setTimer

public setTimer(b:boolean):Void

Used to start and stop the graphical game timer when a task is accepted .

Parameters:
        b - boolean value representing start ( the timer ) and stop ( the timer )

Returns:
        Void -

See also:


processKey

public static processKey(keyCode:Number, GameActionKey:Number):boolean

Called by other classes to triger appropriate actions when key is pressed on the devices keypad . Flags are checked to see what is current displayed on the device e . g . it may be the World , TaskHut or OptionsScreen , etc etc . A simple if / else structure is used to pass the keyPressed event to the appropriate class to deal with .

Parameters:
        keyCode - Integer value representing the pressed key
        GameActionKey - Integer value representing game action associated with more than one key

Returns:
        boolean -

See also:



Event Detail

onMouseClick

public onMouseClick(void):void

Parameters:
        void -

Returns:
        void -

See also:


onKeyPress

public onKeyPress():void

Parameters:

Returns:
        void -

See also: