itemaction.java.svn-base
来自「一个JAVA程序员的游戏」· SVN-BASE 代码 · 共 36 行
SVN-BASE
36 行
/*
* ItemAction.java
*
* Created on 30. Dezember 2006, 14:24
*
* To change this template, choose Tools | Template Manager
* and open the template in the editor.
*/
package kanjitori.action;
import com.jme.input.action.InputAction;
import com.jme.input.action.InputActionEvent;
import kanjitori.graphics.item.Item;
import kanjitori.Level;
import kanjitori.Player;
/**
*
* @author Pirx
*/
public class ItemAction extends InputAction {
private Item.Type type;
/** Creates a new instance of ItemAction */
public ItemAction(Item.Type type) {
this.type = type;
}
public void performAction(InputActionEvent evt) {
Player.getPlayer().useItem(type);
}
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?