fugitivegame.java

来自「J2ME手机游戏,可以下下玩完,很好玩的.」· Java 代码 · 共 63 行

JAVA
63
字号
package Src; 
import javax.microedition.midlet.MIDlet;
import javax.microedition.midlet.MIDletStateChangeException;
import javax.microedition.lcdui.*;

public class FugitiveGame extends MIDlet {

	private Display display;
	public static int Gametime;//全类静态变量获取游戏时间
	
	public FugitiveGame() {
		Gametime=0;
		display=Display.getDisplay(this);	
	}
	
 

	protected void destroyApp(boolean arg0) throws MIDletStateChangeException {
		// TODO Auto-generated method stub

	}

	protected void pauseApp() {
		// TODO Auto-generated method stub

	}
	public void help()//帮助
	{
		Help help=new Help(this);
		display.setCurrent(help);
	}
	public void BestTime()//游戏记录
	{
		Besttime besttime=new Besttime(this);
		display.setCurrent(besttime);
	}
	public void back()//返回主菜单
	{
		GameChoice GameChoice=new GameChoice(this);
		new Thread(GameChoice).start();
		display.setCurrent(GameChoice);
	}
	public void Start()//游戏开始
	{

		Gamestart Game=new Gamestart(20,this);
		Game.start();
		display.setCurrent(Game);
	}
	public void GameStop()//游戏停止
	{

		GameOver GameStop=new GameOver(this,Gametime);
		display.setCurrent(GameStop);
	}
	protected void startApp() throws MIDletStateChangeException {
		GameChoice Game=new GameChoice(this);
		new Thread(Game).start();
		display.setCurrent(Game);
	}

}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?