?? floorsprite.java
字號:
import javax.microedition.lcdui.game.Sprite;import javax.microedition.lcdui.*;/** * <p>Title: </p> * <p>Description: </p> * <p>Copyright: Copyright (c) 2004</p> * <p>Company: </p> * @author not attributable * @version 1.0 */public abstract class floorSprite extends Sprite { public static int FLOOR_MOVE = 1; private int frameWidth; private int frameHeight; private int scnWidth; private int scnHeight; private int frameNum; public boolean isTurn; public boolean isDoLive;// public boolean isOn; public floorSprite(Image img, int frameWidth, int frameHeight, int scnWidth, int scnHeight) { super(img, frameWidth, frameHeight); this.frameWidth = frameWidth; this.frameHeight = frameHeight; this.scnWidth = scnWidth; this.scnHeight = scnHeight; } public void init(int x, int y) {// isOn = false; isTurn = false; isDoLive = false; frameNum = 0; setFrame(0);// if (getHeight() > 5)// setPosition(x, y-(getHeight()-5));// else setPosition(x, y); } public boolean moveUp() { int y = getY(); y = getHeight(); if (getY() + getHeight() - FLOOR_MOVE > 0) { move(0, -1 * FLOOR_MOVE); return true; } return false; } abstract void doOn(playerSprite tempPlayer); abstract void autoAction();}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -