⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 instruction.java

📁 j2me的坦克大战 元代码 单机版和蓝牙联网版
💻 JAVA
字号:
import javax.microedition.lcdui.Command;import javax.microedition.lcdui.CommandListener;import javax.microedition.lcdui.Displayable;import javax.microedition.lcdui.Form;import javax.microedition.lcdui.StringItem; public class Instruction extends Form implements CommandListener{    private GameMidlet gameMidlet;    private Command cmdExit;    public Instruction (GameMidlet gameMidlet) {        super("Game Instruct");        this.gameMidlet = gameMidlet;        cmdExit = new Command("Back",Command.EXIT,1);        String instruc = "  Your task is kill all enemy and protect your fort,press up down,left right to move your tank,press middle to fire.";        StringItem item = new StringItem("GameInstruct",instruc);        append(item);        addCommand(cmdExit);        this.setCommandListener(this);    }    public void commandAction(Command arg0, Displayable arg1) {        if(arg0 == cmdExit) {            gameMidlet.gameMenuCanvasBack();        }    }}

⌨️ 快捷键说明

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