本文整理汇总了Java中org.rev317.min.api.events.GameActionEvent类的典型用法代码示例。如果您正苦于以下问题:Java GameActionEvent类的具体用法?Java GameActionEvent怎么用?Java GameActionEvent使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
GameActionEvent类属于org.rev317.min.api.events包,在下文中一共展示了GameActionEvent类的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: intercept
import org.rev317.min.api.events.GameActionEvent; //导入依赖的package包/类
public static void intercept(int index) {
int outputIndex = 0;
Client client = Loader.getClient();
int action1 = client.getMenuAction1()[index];
int action2 = client.getMenuAction2()[index];
int action3 = client.getMenuAction3()[index];
int action4 = 0;
int actionId = client.getMenuActionId()[index];
if (DActions.debugActions()) {
if (Game.hasAction4()) {
action4 = client.getMenuAction4()[index];
System.out.println(String.format(outputs[0][outputIndex], index, action1, action2, action3, action4, actionId));
} else {
System.out.println(String.format(outputs[1][outputIndex], index, action1, action2, action3, actionId));
}
}
final GameActionEvent actionEvent = new GameActionEvent(actionId, action1, action2, action3, action4, index);
ScriptEngine.getInstance().dispatch(actionEvent);
}
示例2: dispatch
import org.rev317.min.api.events.GameActionEvent; //导入依赖的package包/类
public void dispatch(GameActionEvent event) {
for (final GameActionListener a : actionListeners) {
a.onGameAction(event);
}
}
示例3: onGameAction
import org.rev317.min.api.events.GameActionEvent; //导入依赖的package包/类
void onGameAction(GameActionEvent event);