|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
|
+--javax.microedition.midlet.MIDlet
|
+--MadnessMIDlet
Class MadnessMIDlet is the super class. it handels the display mainly switching between the menus and the game. it handles the required events specfic for apllication deployment to a mobile handset. it handels any loading of files in the res folder and the recordstore
Title: Monkey Madness
Description: Player must run arround field, destroying and avoiding bombs, droids and boss.
Copyright: Copyright (c) 2005
Company: Pistachio Monkey
| Field Summary | |
BluetoothHandle |
btHandle
|
int |
level
|
int |
levelDroids
|
int |
lives
|
int |
points
|
int |
wallNumber
|
| Constructor Summary | |
MadnessMIDlet()
Holds no constructors |
|
| Method Summary | |
void |
bluetoothClient()
sets the handset to act as the Client of a bluetooth game |
void |
bluetoothHost()
sets the handset to act as the Host of a bluetooth game |
boolean |
checkHighScore()
checks to see if the current score is high, if so, it writes it to the record store and returns true |
void |
destroyApp(boolean unconditional)
calls a stop to the levelCanvas |
void |
gameOver()
refreshes the game stats & creates an instance of the GameOverScreen class |
void |
gameOverDone()
returns the display back to the MenuList and calls stopMusic() |
BluetoothHandle |
getBluetooth()
returns the BluetoothHandle |
LevelCanvas |
getCanvas()
returns the LevelCanvas |
int |
getHighScore()
returns an int of the highest score |
void |
levelCanvasMenu()
refreshes game stats, calls the animation thread to a stop and returns the display back to the also calls stopMusic() if soundOn |
void |
menuList()
resturns the display back to the MenuList |
void |
menuListBluetoothGame()
creates a new Bluetooth list menu |
void |
menuListBluetoothLevel()
goes about building a multiplayer game, changes the display to the LevelCanvas, and calls playMusic() if soundOn |
void |
menuListContinue()
returns the diaplay back tot the canvas, restarts the LevelCanvas and makes the player invincible |
void |
menuListHighScore()
changes the display & creates an instance of the HighScoreScreen |
void |
menuListInstructions()
creates a new Instructions screen |
void |
menuListNewGame()
calls the initlaiser on the LevelCanvas and then the start's the game, while changing the display to the LevelCanvas, if soundOn then it calls to playMusic() |
void |
menuListQuit()
quits the application and calls a stopMusic() |
void |
nextLevel()
refreshes the game stats & creates an instance of the NextLevelScreen class |
void |
nextLevelDone()
returns to the LevelCanvas |
void |
pauseApp()
hear we handle the occurance of a pause, the animation thread is stoped |
void |
playBang()
creats a new player to play /bang.wav, not called anywhere and thus temporaryly disabled |
void |
playMusic()
palys the music loop's it for 100 counts |
int |
readRecordStore()
reads the record store and returns an int value |
void |
refresh()
refreshes the MIDlet variables of game statistics such that they can be accessed by other children classes |
void |
run()
calls the init() initilzer method |
void |
splashScreenPainted()
creates a thread while the splash screen is painted |
void |
startApp()
inititation of the app and we decide weather this is the first time. |
void |
stopMusic()
closes the songPlayer |
void |
vibrate(int millis)
causes the display to vibrate for a passed int in millieseconds |
| Methods inherited from class javax.microedition.midlet.MIDlet |
checkPermission, getAppProperty, notifyDestroyed, notifyPaused, platformRequest, resumeRequest |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public int level
public int lives
public int points
public int wallNumber
public int levelDroids
public BluetoothHandle btHandle
| Constructor Detail |
public MadnessMIDlet()
| Method Detail |
public void startApp()
startApp in class javax.microedition.midlet.MIDletpublic void pauseApp()
pauseApp in class javax.microedition.midlet.MIDletpublic void destroyApp(boolean unconditional)
destroyApp in class javax.microedition.midlet.MIDletunconditional - boolean value must be passed, false will ativatepublic void run()
run in interface java.lang.Runnablepublic void splashScreenPainted()
public void menuListContinue()
public void menuListNewGame()
public LevelCanvas getCanvas()
public BluetoothHandle getBluetooth()
public void menuListBluetoothLevel()
public void menuListInstructions()
public void menuListQuit()
public void menuListBluetoothGame()
public void nextLevelDone()
public void nextLevel()
public void gameOver()
public void gameOverDone()
public void menuList()
public void menuListHighScore()
public void refresh()
public void levelCanvasMenu()
public void vibrate(int millis)
millis - vibrates the display for this period in milliesecondspublic int getHighScore()
public boolean checkHighScore()
public int readRecordStore()
public void playMusic()
public void stopMusic()
public void playBang()
public void bluetoothHost()
public void bluetoothClient()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||