forked from MagicBane/Server
Handler created for PerformActionMsg
This commit is contained in:
@@ -795,16 +795,9 @@ public class ClientMessagePump implements NetMsgHandler {
|
||||
case LEADERCHANNELMESSAGE:
|
||||
ChatManager.handleChatMsg(s, (AbstractChatMsg) msg);
|
||||
break;
|
||||
case CHECKUNIQUEGUILD:
|
||||
break;
|
||||
case CANCELGUILDCREATION:
|
||||
break;
|
||||
case LEAVEREQUEST:
|
||||
origin.disconnect();
|
||||
break;
|
||||
case POWER:
|
||||
PowersManager.usePower((PerformActionMsg) msg, origin, false);
|
||||
break;
|
||||
case READYTOENTER:
|
||||
break;
|
||||
case OPENVAULT:
|
||||
|
||||
@@ -157,7 +157,7 @@ public enum Protocol {
|
||||
PLACEASSET(0x940962DF, PlaceAssetMsg.class, PlaceAssetMsgHandler.class),
|
||||
PLAYERDATA(0xB206D352, SendOwnPlayerMsg.class, null), //Enter World, Own Player Data
|
||||
PLAYERFRIENDS(0xDDEF9E7D, FriendRequestMsg.class, FriendRequestHandler.class),
|
||||
POWER(0x3C97A459, PerformActionMsg.class, null), // REQ / CMD Perform Action
|
||||
POWER(0x3C97A459, PerformActionMsg.class, PerformActionMsgHandler.class), // REQ / CMD Perform Action
|
||||
POWERACTION(0xA0B27EEB, ApplyEffectMsg.class, null), // Apply Effect, add to effects icons
|
||||
POWERACTIONDD(0xD43052F8, ModifyHealthMsg.class, null), //Modify Health/Mana/Stamina using power
|
||||
POWERACTIONDDDIE(0xC27D446B, null, null), //Modify Health/Mana/Stamina using power and kill target
|
||||
|
||||
@@ -0,0 +1,33 @@
|
||||
// • ▌ ▄ ·. ▄▄▄· ▄▄ • ▪ ▄▄· ▄▄▄▄· ▄▄▄· ▐▄▄▄ ▄▄▄ .
|
||||
// ·██ ▐███▪▐█ ▀█ ▐█ ▀ ▪██ ▐█ ▌▪▐█ ▀█▪▐█ ▀█ •█▌ ▐█▐▌·
|
||||
// ▐█ ▌▐▌▐█·▄█▀▀█ ▄█ ▀█▄▐█·██ ▄▄▐█▀▀█▄▄█▀▀█ ▐█▐ ▐▌▐▀▀▀
|
||||
// ██ ██▌▐█▌▐█ ▪▐▌▐█▄▪▐█▐█▌▐███▌██▄▪▐█▐█ ▪▐▌██▐ █▌▐█▄▄▌
|
||||
// ▀▀ █▪▀▀▀ ▀ ▀ ·▀▀▀▀ ▀▀▀·▀▀▀ ·▀▀▀▀ ▀ ▀ ▀▀ █▪ ▀▀▀
|
||||
// Magicbane Emulator Project © 2013 - 2022
|
||||
// www.magicbane.com
|
||||
|
||||
package engine.net.client.handlers;
|
||||
|
||||
import engine.exception.MsgSendException;
|
||||
import engine.gameManager.PowersManager;
|
||||
import engine.net.client.ClientConnection;
|
||||
import engine.net.client.msg.ClientNetMsg;
|
||||
import engine.net.client.msg.KeepAliveServerClientMsg;
|
||||
import engine.net.client.msg.PerformActionMsg;
|
||||
|
||||
public class PerformActionMsgHandler extends AbstractClientMsgHandler {
|
||||
|
||||
public PerformActionMsgHandler() {
|
||||
super(KeepAliveServerClientMsg.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected boolean _handleNetMsg(ClientNetMsg baseMsg, ClientConnection origin) throws MsgSendException {
|
||||
|
||||
PerformActionMsg msg = (PerformActionMsg) baseMsg;
|
||||
PowersManager.usePower(msg, origin, false); // Wtf ?
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user