summaryrefslogtreecommitdiff
path: root/src/net
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-08-24 17:01:22 +0300
committerAndrei Karas <akaras@inbox.ru>2015-08-24 17:01:22 +0300
commit3fc6d30634ea19569caaa1e8887378eef9c4505d (patch)
tree86079d581aae2585c6f21a936fca0876d7244703 /src/net
parent4ea298eef5d60e7101844add7f352d4539ea9dd7 (diff)
downloadmanaverse-3fc6d30634ea19569caaa1e8887378eef9c4505d.tar.gz
manaverse-3fc6d30634ea19569caaa1e8887378eef9c4505d.tar.bz2
manaverse-3fc6d30634ea19569caaa1e8887378eef9c4505d.tar.xz
manaverse-3fc6d30634ea19569caaa1e8887378eef9c4505d.zip
Rename being receive handler into beingrecv.
Diffstat (limited to 'src/net')
-rw-r--r--src/net/ea/beinghandler.cpp6
-rw-r--r--src/net/ea/beingrecv.cpp (renamed from src/net/ea/beingnet.cpp)106
-rw-r--r--src/net/ea/beingrecv.h (renamed from src/net/ea/beingnet.h)4
-rw-r--r--src/net/eathena/beinghandler.cpp130
-rw-r--r--src/net/eathena/beingrecv.cpp (renamed from src/net/eathena/beingnet.cpp)264
-rw-r--r--src/net/eathena/beingrecv.h (renamed from src/net/eathena/beingnet.h)4
-rw-r--r--src/net/tmwa/beinghandler.cpp62
-rw-r--r--src/net/tmwa/beingrecv.cpp (renamed from src/net/tmwa/beingnet.cpp)251
-rw-r--r--src/net/tmwa/beingrecv.h (renamed from src/net/tmwa/beingnet.h)4
9 files changed, 416 insertions, 415 deletions
diff --git a/src/net/ea/beinghandler.cpp b/src/net/ea/beinghandler.cpp
index 49e8b4720..56fea0fc7 100644
--- a/src/net/ea/beinghandler.cpp
+++ b/src/net/ea/beinghandler.cpp
@@ -40,7 +40,7 @@
#include "net/serverfeatures.h"
-#include "net/ea/beingnet.h"
+#include "net/ea/beingrecv.h"
#include "debug.h"
@@ -49,8 +49,8 @@ namespace Ea
BeingHandler::BeingHandler(const bool enableSync)
{
- BeingNet::mSync = enableSync;
- BeingNet::mSpawnId = BeingId_zero;
+ BeingRecv::mSync = enableSync;
+ BeingRecv::mSpawnId = BeingId_zero;
}
} // namespace Ea
diff --git a/src/net/ea/beingnet.cpp b/src/net/ea/beingrecv.cpp
index 621e76b0c..047b77653 100644
--- a/src/net/ea/beingnet.cpp
+++ b/src/net/ea/beingrecv.cpp
@@ -20,7 +20,7 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-#include "net/ea/beingnet.h"
+#include "net/ea/beingrecv.h"
#include "actormanager.h"
#include "game.h"
@@ -45,18 +45,18 @@
namespace Ea
{
-namespace BeingNet
+namespace BeingRecv
{
bool mSync = false;
BeingId mSpawnId = BeingId_zero;
-} // namespace BeingNet
+} // namespace BeingRecv
-void BeingNet::processBeingRemove(Net::MessageIn &msg)
+void BeingRecv::processBeingRemove(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processBeingRemove")
+ BLOCK_START("BeingRecv::processBeingRemove")
if (!actorManager || !localPlayer)
{
- BLOCK_END("BeingNet::processBeingRemove")
+ BLOCK_END("BeingRecv::processBeingRemove")
return;
}
@@ -67,7 +67,7 @@ void BeingNet::processBeingRemove(Net::MessageIn &msg)
if (!dstBeing)
{
msg.readUInt8("dead flag?");
- BLOCK_END("BeingNet::processBeingRemove")
+ BLOCK_END("BeingRecv::processBeingRemove")
return;
}
@@ -95,15 +95,15 @@ void BeingNet::processBeingRemove(Net::MessageIn &msg)
}
actorManager->destroy(dstBeing);
}
- BLOCK_END("BeingNet::processBeingRemove")
+ BLOCK_END("BeingRecv::processBeingRemove")
}
-void BeingNet::processSkillDamage(Net::MessageIn &msg)
+void BeingRecv::processSkillDamage(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processSkillDamage")
+ BLOCK_START("BeingRecv::processSkillDamage")
if (!actorManager)
{
- BLOCK_END("BeingNet::processSkillDamage")
+ BLOCK_END("BeingRecv::processSkillDamage")
return;
}
@@ -123,15 +123,15 @@ void BeingNet::processSkillDamage(Net::MessageIn &msg)
srcBeing->handleSkill(dstBeing, param1, id, level);
if (dstBeing)
dstBeing->takeDamage(srcBeing, param1, AttackType::SKILL, id, level);
- BLOCK_END("BeingNet::processSkillDamage")
+ BLOCK_END("BeingRecv::processSkillDamage")
}
-void BeingNet::processBeingAction(Net::MessageIn &msg)
+void BeingRecv::processBeingAction(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processBeingAction")
+ BLOCK_START("BeingRecv::processBeingAction")
if (!actorManager)
{
- BLOCK_END("BeingNet::processBeingAction")
+ BLOCK_END("BeingRecv::processBeingAction")
return;
}
@@ -218,15 +218,15 @@ void BeingNet::processBeingAction(Net::MessageIn &msg)
UNIMPLIMENTEDPACKET;
break;
}
- BLOCK_END("BeingNet::processBeingAction")
+ BLOCK_END("BeingRecv::processBeingAction")
}
-void BeingNet::processBeingEmotion(Net::MessageIn &msg)
+void BeingRecv::processBeingEmotion(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processBeingEmotion")
+ BLOCK_START("BeingRecv::processBeingEmotion")
if (!localPlayer || !actorManager)
{
- BLOCK_END("BeingNet::processBeingEmotion")
+ BLOCK_END("BeingRecv::processBeingEmotion")
return;
}
@@ -234,7 +234,7 @@ void BeingNet::processBeingEmotion(Net::MessageIn &msg)
msg.readBeingId("being id"));
if (!dstBeing)
{
- BLOCK_END("BeingNet::processBeingEmotion")
+ BLOCK_END("BeingRecv::processBeingEmotion")
return;
}
@@ -249,15 +249,15 @@ void BeingNet::processBeingEmotion(Net::MessageIn &msg)
}
if (dstBeing->getType() == ActorType::Player)
dstBeing->setOtherTime();
- BLOCK_END("BeingNet::processBeingEmotion")
+ BLOCK_END("BeingRecv::processBeingEmotion")
}
-void BeingNet::processNameResponse(Net::MessageIn &msg)
+void BeingRecv::processNameResponse(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processNameResponse")
+ BLOCK_START("BeingRecv::processNameResponse")
if (!localPlayer || !actorManager)
{
- BLOCK_END("BeingNet::processNameResponse")
+ BLOCK_END("BeingRecv::processNameResponse")
return;
}
@@ -305,20 +305,20 @@ void BeingNet::processNameResponse(Net::MessageIn &msg)
}
localPlayer->checkNewName(dstBeing);
}
- BLOCK_END("BeingNet::processNameResponse")
+ BLOCK_END("BeingRecv::processNameResponse")
return;
}
}
msg.readString(24, "name");
- BLOCK_END("BeingNet::processNameResponse")
+ BLOCK_END("BeingRecv::processNameResponse")
}
-void BeingNet::processPlayerStop(Net::MessageIn &msg)
+void BeingRecv::processPlayerStop(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processPlayerStop")
+ BLOCK_START("BeingRecv::processPlayerStop")
if (!actorManager || !localPlayer)
{
- BLOCK_END("BeingNet::processPlayerStop")
+ BLOCK_END("BeingRecv::processPlayerStop")
return;
}
@@ -334,18 +334,18 @@ void BeingNet::processPlayerStop(Net::MessageIn &msg)
dstBeing->setTileCoords(x, y);
if (dstBeing->getCurrentAction() == BeingAction::MOVE)
dstBeing->setAction(BeingAction::STAND, 0);
- BLOCK_END("BeingNet::processPlayerStop")
+ BLOCK_END("BeingRecv::processPlayerStop")
return;
}
}
msg.readInt16("x");
msg.readInt16("y");
- BLOCK_END("BeingNet::processPlayerStop")
+ BLOCK_END("BeingRecv::processPlayerStop")
}
-void BeingNet::processPlayerMoveToAttack(Net::MessageIn &msg)
+void BeingRecv::processPlayerMoveToAttack(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processPlayerStop")
+ BLOCK_START("BeingRecv::processPlayerStop")
msg.readInt32("target id");
msg.readInt16("target x");
msg.readInt16("target y");
@@ -355,10 +355,10 @@ void BeingNet::processPlayerMoveToAttack(Net::MessageIn &msg)
if (localPlayer)
localPlayer->fixAttackTarget();
- BLOCK_END("BeingNet::processPlayerStop")
+ BLOCK_END("BeingRecv::processPlayerStop")
}
-void BeingNet::processSkillNoDamage(Net::MessageIn &msg)
+void BeingRecv::processSkillNoDamage(Net::MessageIn &msg)
{
const int id = msg.readInt16("skill id");
const int heal = msg.readInt16("heal");
@@ -372,28 +372,28 @@ void BeingNet::processSkillNoDamage(Net::MessageIn &msg)
srcBeing->handleSkill(dstBeing, heal, id, 1);
}
-void BeingNet::processPvpMapMode(Net::MessageIn &msg)
+void BeingRecv::processPvpMapMode(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processPvpMapMode")
+ BLOCK_START("BeingRecv::processPvpMapMode")
const Game *const game = Game::instance();
if (!game)
{
- BLOCK_END("BeingNet::processPvpMapMode")
+ BLOCK_END("BeingRecv::processPvpMapMode")
return;
}
Map *const map = game->getCurrentMap();
if (map)
map->setPvpMode(msg.readInt16("pvp mode"));
- BLOCK_END("BeingNet::processPvpMapMode")
+ BLOCK_END("BeingRecv::processPvpMapMode")
}
-void BeingNet::processBeingMove3(Net::MessageIn &msg)
+void BeingRecv::processBeingMove3(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processBeingMove3")
+ BLOCK_START("BeingRecv::processBeingMove3")
if (!actorManager || !serverFeatures->haveMove3())
{
- BLOCK_END("BeingNet::processBeingMove3")
+ BLOCK_END("BeingRecv::processBeingMove3")
return;
}
@@ -405,7 +405,7 @@ void BeingNet::processBeingMove3(Net::MessageIn &msg)
msg.readBeingId("being id"));
if (!dstBeing)
{
- BLOCK_END("BeingNet::processBeingMove3")
+ BLOCK_END("BeingRecv::processBeingMove3")
return;
}
const int16_t speed = msg.readInt16("speed");
@@ -433,11 +433,11 @@ void BeingNet::processBeingMove3(Net::MessageIn &msg)
delete [] moves;
}
dstBeing->setPath(path);
- BLOCK_END("BeingNet::processBeingMove3")
+ BLOCK_END("BeingRecv::processBeingMove3")
}
-Being *BeingNet::createBeing(const BeingId id,
- const int job)
+Being *BeingRecv::createBeing(const BeingId id,
+ const int job)
{
if (!actorManager)
return nullptr;
@@ -457,13 +457,13 @@ Being *BeingNet::createBeing(const BeingId id,
return being;
}
-void BeingNet::setSprite(Being *const being,
- const unsigned int slot,
- const int id,
- const std::string &color,
- const ItemColor colorId,
- const bool isWeapon,
- const bool isTempSprite)
+void BeingRecv::setSprite(Being *const being,
+ const unsigned int slot,
+ const int id,
+ const std::string &color,
+ const ItemColor colorId,
+ const bool isWeapon,
+ const bool isTempSprite)
{
if (!being)
return;
diff --git a/src/net/ea/beingnet.h b/src/net/ea/beingrecv.h
index c32a49b9f..0fb51ebe7 100644
--- a/src/net/ea/beingnet.h
+++ b/src/net/ea/beingrecv.h
@@ -27,7 +27,7 @@
namespace Ea
{
- namespace BeingNet
+ namespace BeingRecv
{
extern bool mSync;
extern BeingId mSpawnId;
@@ -54,6 +54,6 @@ namespace Ea
} // namespace Ea
-//extern bool Ea::BeingNet::mSync;
+//extern bool Ea::BeingRecv::mSync;
#endif // NET_EA_BEING_H
diff --git a/src/net/eathena/beinghandler.cpp b/src/net/eathena/beinghandler.cpp
index 11a1ced05..6273d2202 100644
--- a/src/net/eathena/beinghandler.cpp
+++ b/src/net/eathena/beinghandler.cpp
@@ -49,9 +49,9 @@
#include "net/character.h"
-#include "net/ea/beingnet.h"
+#include "net/ea/beingrecv.h"
-#include "net/eathena/beingnet.h"
+#include "net/eathena/beingrecv.h"
#include "net/eathena/maptypeproperty2.h"
#include "net/eathena/messageout.h"
#include "net/eathena/protocol.h"
@@ -161,126 +161,126 @@ void BeingHandler::handleMessage(Net::MessageIn &msg)
switch (msg.getId())
{
case SMSG_BEING_VISIBLE:
- BeingNet::processBeingVisible(msg);
+ BeingRecv::processBeingVisible(msg);
break;
case SMSG_BEING_MOVE:
- BeingNet::processBeingMove(msg);
+ BeingRecv::processBeingMove(msg);
break;
case SMSG_BEING_SPAWN:
- BeingNet::processBeingSpawn(msg);
+ BeingRecv::processBeingSpawn(msg);
break;
case SMSG_BEING_MOVE2:
- BeingNet::processBeingMove2(msg);
+ BeingRecv::processBeingMove2(msg);
break;
case SMSG_BEING_REMOVE:
- Ea::BeingNet::processBeingRemove(msg);
+ Ea::BeingRecv::processBeingRemove(msg);
break;
case SMSG_BEING_REMOVE_SKILL:
- BeingNet::processBeingRemoveSkil(msg);
+ BeingRecv::processBeingRemoveSkil(msg);
break;
case SMSG_BEING_RESURRECT:
- BeingNet::processBeingResurrect(msg);
+ BeingRecv::processBeingResurrect(msg);
break;
case SMSG_SKILL_DAMAGE:
- Ea::BeingNet::processSkillDamage(msg);
+ Ea::BeingRecv::processSkillDamage(msg);
break;
case SMSG_SKILL_AUTO_CAST:
- BeingNet::processSkillAutoCast(msg);
+ BeingRecv::processSkillAutoCast(msg);
break;
case SMSG_BEING_ACTION:
- Ea::BeingNet::processBeingAction(msg);
+ Ea::BeingRecv::processBeingAction(msg);
break;
case SMSG_BEING_ACTION2:
- BeingNet::processBeingAction2(msg);
+ BeingRecv::processBeingAction2(msg);
break;
case SMSG_BEING_SELFEFFECT:
- BeingNet::processBeingSelfEffect(msg);
+ BeingRecv::processBeingSelfEffect(msg);
break;
case SMSG_BEING_SPECIAL_EFFECT:
- BeingNet::processBeingSpecialEffect(msg);
+ BeingRecv::processBeingSpecialEffect(msg);
break;
case SMSG_BEING_SPECIAL_EFFECT_NUM:
- BeingNet::processBeingSpecialEffectNum(msg);
+ BeingRecv::processBeingSpecialEffectNum(msg);
break;
case SMSG_BEING_SOUND_EFFECT:
- BeingNet::processBeingSoundEffect(msg);
+ BeingRecv::processBeingSoundEffect(msg);
break;
case SMSG_BEING_EMOTION:
- Ea::BeingNet::processBeingEmotion(msg);
+ Ea::BeingRecv::processBeingEmotion(msg);
break;
case SMSG_BEING_CHANGE_LOOKS2:
- BeingNet::processBeingChangeLook2(msg);
+ BeingRecv::processBeingChangeLook2(msg);
break;
case SMSG_BEING_CHANGE_LOOKS_CARDS:
- BeingNet::processBeingChangeLookCards(msg);
+ BeingRecv::processBeingChangeLookCards(msg);
break;
case SMSG_BEING_NAME_RESPONSE:
- Ea::BeingNet::processNameResponse(msg);
+ Ea::BeingRecv::processNameResponse(msg);
break;
case SMSG_BEING_NAME_RESPONSE2:
- BeingNet::processNameResponse2(msg);
+ BeingRecv::processNameResponse2(msg);
break;
case SMSG_SOLVE_CHAR_NAME:
break;
case SMSG_PLAYER_GUILD_PARTY_INFO:
- BeingNet::processPlayerGuilPartyInfo(msg);
+ BeingRecv::processPlayerGuilPartyInfo(msg);
break;
case SMSG_BEING_CHANGE_DIRECTION:
- BeingNet::processBeingChangeDirection(msg);
+ BeingRecv::processBeingChangeDirection(msg);
break;
case SMSG_PLAYER_STOP:
- Ea::BeingNet::processPlayerStop(msg);
+ Ea::BeingRecv::processPlayerStop(msg);
break;
case SMSG_PLAYER_MOVE_TO_ATTACK:
- Ea::BeingNet::processPlayerMoveToAttack(msg);
+ Ea::BeingRecv::processPlayerMoveToAttack(msg);
break;
case SMSG_PLAYER_STATUS_CHANGE:
- BeingNet::processPlaterStatusChange(msg);
+ BeingRecv::processPlaterStatusChange(msg);
break;
case SMSG_PLAYER_STATUS_CHANGE2:
- BeingNet::processPlaterStatusChange2(msg);
+ BeingRecv::processPlaterStatusChange2(msg);
break;
case SMSG_PLAYER_STATUS_CHANGE_NO_TICK:
- BeingNet::processPlaterStatusChangeNoTick(msg);
+ BeingRecv::processPlaterStatusChangeNoTick(msg);
break;
case SMSG_BEING_STATUS_CHANGE:
- BeingNet::processBeingStatusChange(msg);
+ BeingRecv::processBeingStatusChange(msg);
break;
case SMSG_BEING_STATUS_CHANGE2:
- BeingNet::processBeingStatusChange2(msg);
+ BeingRecv::processBeingStatusChange2(msg);
break;
case SMSG_SKILL_CASTING:
- BeingNet::processSkillCasting(msg);
+ BeingRecv::processSkillCasting(msg);
break;
case SMSG_SKILL_CAST_CANCEL:
@@ -288,136 +288,136 @@ void BeingHandler::handleMessage(Net::MessageIn &msg)
break;
case SMSG_SKILL_NO_DAMAGE:
- Ea::BeingNet::processSkillNoDamage(msg);
+ Ea::BeingRecv::processSkillNoDamage(msg);
break;
case SMSG_SKILL_GROUND_NO_DAMAGE:
- BeingNet::processSkillGroundNoDamage(msg);
+ BeingRecv::processSkillGroundNoDamage(msg);
break;
case SMSG_SKILL_ENTRY:
- BeingNet::processSkillEntry(msg);
+ BeingRecv::processSkillEntry(msg);
break;
case SMSG_PVP_MAP_MODE:
- Ea::BeingNet::processPvpMapMode(msg);
+ Ea::BeingRecv::processPvpMapMode(msg);
break;
case SMSG_PVP_SET:
- BeingNet::processPvpSet(msg);
+ BeingRecv::processPvpSet(msg);
break;
case SMSG_MAP_TYPE_PROPERTY2:
- BeingNet::processMapTypeProperty(msg);
+ BeingRecv::processMapTypeProperty(msg);
break;
case SMSG_MAP_TYPE:
- BeingNet::processMapType(msg);
+ BeingRecv::processMapType(msg);
break;
case SMSG_MONSTER_HP:
case SMSG_PLAYER_HP:
- BeingNet::processMonsterHp(msg);
+ BeingRecv::processMonsterHp(msg);
break;
case SMSG_RANKS_LIST:
- BeingNet::processRanksList(msg);
+ BeingRecv::processRanksList(msg);
break;
case SMSG_BEING_FAKE_NAME:
- BeingNet::processBeingFakeName(msg);
+ BeingRecv::processBeingFakeName(msg);
break;
case SMSG_BEING_STAT_UPDATE_1:
- BeingNet::processBeingStatUpdate1(msg);
+ BeingRecv::processBeingStatUpdate1(msg);
break;
case SMSG_MOB_INFO:
- BeingNet::processMobInfo(msg);
+ BeingRecv::processMobInfo(msg);
break;
case SMSG_BEING_MOVE3:
- Ea::BeingNet::processBeingMove3(msg);
+ Ea::BeingRecv::processBeingMove3(msg);
break;
case SMSG_BEING_ATTRS:
- BeingNet::processBeingAttrs(msg);
+ BeingRecv::processBeingAttrs(msg);
break;
case SMSG_MONSTER_INFO:
- BeingNet::processMonsterInfo(msg);
+ BeingRecv::processMonsterInfo(msg);
break;
case SMSG_CLASS_CHANGE:
- BeingNet::processClassChange(msg);
+ BeingRecv::processClassChange(msg);
break;
case SMSG_SPIRIT_BALLS:
- BeingNet::processSpiritBalls(msg);
+ BeingRecv::processSpiritBalls(msg);
break;
case SMSG_SPIRIT_BALL_SINGLE:
- BeingNet::processSpiritBallSingle(msg);
+ BeingRecv::processSpiritBallSingle(msg);
break;
case SMSG_BLADE_STOP:
- BeingNet::processBladeStop(msg);
+ BeingRecv::processBladeStop(msg);
break;
case SMSG_COMBO_DELAY:
- BeingNet::processComboDelay(msg);
+ BeingRecv::processComboDelay(msg);
break;
case SMSG_WEDDING_EFFECT:
- BeingNet::processWddingEffect(msg);
+ BeingRecv::processWddingEffect(msg);
break;
case SMSG_BEING_SLIDE:
- BeingNet::processBeingSlide(msg);
+ BeingRecv::processBeingSlide(msg);
break;
case SMSG_STARS_KILL:
- BeingNet::processStarsKill(msg);
+ BeingRecv::processStarsKill(msg);
break;
case SMSG_BLACKSMITH_RANKS_LIST:
- BeingNet::processBlacksmithRanksList(msg);
+ BeingRecv::processBlacksmithRanksList(msg);
break;
case SMSG_ALCHEMIST_RANKS_LIST:
- BeingNet::processAlchemistRanksList(msg);
+ BeingRecv::processAlchemistRanksList(msg);
break;
case SMSG_TAEKWON_RANKS_LIST:
- BeingNet::processTaekwonRanksList(msg);
+ BeingRecv::processTaekwonRanksList(msg);
break;
case SMSG_PK_RANKS_LIST:
- BeingNet::processPkRanksList(msg);
+ BeingRecv::processPkRanksList(msg);
break;
case SMSG_GLADIATOR_FEEL_REQUEST:
- BeingNet::processGladiatorFeelRequest(msg);
+ BeingRecv::processGladiatorFeelRequest(msg);
break;
case SMSG_BOSS_MAP_INFO:
- BeingNet::processBossMapInfo(msg);
+ BeingRecv::processBossMapInfo(msg);
break;
case SMSG_BEING_FONT:
- BeingNet::processBeingFont(msg);
+ BeingRecv::processBeingFont(msg);
break;
case SMSG_BEING_MILLENIUM_SHIELD:
- BeingNet::processBeingMilleniumShield(msg);
+ BeingRecv::processBeingMilleniumShield(msg);
break;
case SMSG_BEING_CHARM:
- BeingNet::processBeingCharm(msg);
+ BeingRecv::processBeingCharm(msg);
break;
case SMSG_BEING_VIEW_EQUIPMENT:
- BeingNet::processBeingViewEquipment(msg);
+ BeingRecv::processBeingViewEquipment(msg);
break;
default:
diff --git a/src/net/eathena/beingnet.cpp b/src/net/eathena/beingrecv.cpp
index 1da2ddad0..c9c942023 100644
--- a/src/net/eathena/beingnet.cpp
+++ b/src/net/eathena/beingrecv.cpp
@@ -20,7 +20,7 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-#include "net/eathena/beingnet.h"
+#include "net/eathena/beingrecv.h"
#include "actormanager.h"
#include "effectmanager.h"
@@ -43,7 +43,7 @@
#include "net/serverfeatures.h"
-#include "net/ea/beingnet.h"
+#include "net/ea/beingrecv.h"
#include "net/ea/eaprotocol.h"
#include "net/charserverhandler.h"
@@ -67,7 +67,7 @@
namespace EAthena
{
-void BeingNet::processBeingChangeLook2(Net::MessageIn &msg)
+void BeingRecv::processBeingChangeLook2(Net::MessageIn &msg)
{
if (!actorManager)
return;
@@ -87,7 +87,7 @@ void BeingNet::processBeingChangeLook2(Net::MessageIn &msg)
processBeingChangeLookContinue(msg, dstBeing, type, id, id2, nullptr);
}
-void BeingNet::processBeingChangeLookCards(Net::MessageIn &msg)
+void BeingRecv::processBeingChangeLookCards(Net::MessageIn &msg)
{
Being *dstBeing = nullptr;
int cards[4];
@@ -131,12 +131,12 @@ void BeingNet::processBeingChangeLookCards(Net::MessageIn &msg)
processBeingChangeLookContinue(msg, dstBeing, type, id, id2, &cards[0]);
}
-void BeingNet::processBeingChangeLookContinue(Net::MessageIn &msg,
- Being *const dstBeing,
- const uint8_t type,
- const int id,
- const int id2,
- const int *cards A_UNUSED)
+void BeingRecv::processBeingChangeLookContinue(Net::MessageIn &msg,
+ Being *const dstBeing,
+ const uint8_t type,
+ const int id,
+ const int id2,
+ const int *cards A_UNUSED)
{
if (dstBeing->getType() == ActorType::Player)
dstBeing->setOtherTime();
@@ -241,7 +241,7 @@ void BeingNet::processBeingChangeLookContinue(Net::MessageIn &msg,
}
}
-void BeingNet::processBeingVisible(Net::MessageIn &msg)
+void BeingRecv::processBeingVisible(Net::MessageIn &msg)
{
if (!actorManager)
return;
@@ -253,11 +253,11 @@ void BeingNet::processBeingVisible(Net::MessageIn &msg)
// Information about a being in range
const BeingId id = msg.readBeingId("being id");
BeingId spawnId;
- if (id == Ea::BeingNet::mSpawnId)
- spawnId = Ea::BeingNet::mSpawnId;
+ if (id == Ea::BeingRecv::mSpawnId)
+ spawnId = Ea::BeingRecv::mSpawnId;
else
spawnId = BeingId_zero;
- Ea::BeingNet::mSpawnId = BeingId_zero;
+ Ea::BeingRecv::mSpawnId = BeingId_zero;
int16_t speed = msg.readInt16("speed");
const uint16_t stunMode = msg.readInt16("opt1");
@@ -341,16 +341,16 @@ void BeingNet::processBeingVisible(Net::MessageIn &msg)
dstBeing->setGender(Being::intToGender(gender));
dstBeing->setHairColor(hairColor);
// Set these after the gender, as the sprites may be gender-specific
- Ea::BeingNet::setSprite(dstBeing, SPRITE_HAIR_COLOR, hairStyle * -1,
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_HAIR_COLOR, hairStyle * -1,
ItemDB::get(-hairStyle).getDyeColorsString(hairColor));
- Ea::BeingNet::setSprite(dstBeing, SPRITE_WEAPON, headBottom);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_HEAD_BOTTOM, headMid);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_CLOTHES_COLOR, headTop);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_HAIR, shoes);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_SHOES, gloves);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_BODY, weapon, "",
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_WEAPON, headBottom);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_HEAD_BOTTOM, headMid);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_CLOTHES_COLOR, headTop);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_HAIR, shoes);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_SHOES, gloves);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_BODY, weapon, "",
ItemColor_one, true);
-// Ea::BeingNet::setSprite(dstBeing, SPRITE_FLOOR, shield);
+// Ea::BeingRecv::setSprite(dstBeing, SPRITE_FLOOR, shield);
}
else if (dstBeing->getType() == ActorType::Npc
&& serverFeatures->haveNpcGender())
@@ -401,7 +401,7 @@ void BeingNet::processBeingVisible(Net::MessageIn &msg)
statusEffects & 0xffffU));
}
-void BeingNet::processBeingMove(Net::MessageIn &msg)
+void BeingRecv::processBeingMove(Net::MessageIn &msg)
{
if (!actorManager)
return;
@@ -413,11 +413,11 @@ void BeingNet::processBeingMove(Net::MessageIn &msg)
// Information about a being in range
const BeingId id = msg.readBeingId("being id");
BeingId spawnId;
- if (id == Ea::BeingNet::mSpawnId)
- spawnId = Ea::BeingNet::mSpawnId;
+ if (id == Ea::BeingRecv::mSpawnId)
+ spawnId = Ea::BeingRecv::mSpawnId;
else
spawnId = BeingId_zero;
- Ea::BeingNet::mSpawnId = BeingId_zero;
+ Ea::BeingRecv::mSpawnId = BeingId_zero;
int16_t speed = msg.readInt16("speed");
// if (visible)
// {
@@ -504,19 +504,19 @@ void BeingNet::processBeingMove(Net::MessageIn &msg)
dstBeing->setGender(Being::intToGender(gender));
dstBeing->setHairColor(hairColor);
// Set these after the gender, as the sprites may be gender-specific
- Ea::BeingNet::setSprite(dstBeing, SPRITE_HAIR_COLOR, hairStyle * -1,
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_HAIR_COLOR, hairStyle * -1,
ItemDB::get(-hairStyle).getDyeColorsString(hairColor));
if (!serverFeatures->haveMove3())
{
- Ea::BeingNet::setSprite(dstBeing, SPRITE_WEAPON, headBottom);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_HEAD_BOTTOM, headMid);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_CLOTHES_COLOR, headTop);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_HAIR, shoes);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_SHOES, gloves);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_BODY, weapon, "",
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_WEAPON, headBottom);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_HEAD_BOTTOM, headMid);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_CLOTHES_COLOR, headTop);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_HAIR, shoes);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_SHOES, gloves);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_BODY, weapon, "",
ItemColor_one, true);
}
-// Ea::BeingNet::setSprite(dstBeing, SPRITE_FLOOR, shield);
+// Ea::BeingRecv::setSprite(dstBeing, SPRITE_FLOOR, shield);
}
else if (dstBeing->getType() == ActorType::Npc
&& serverFeatures->haveNpcGender())
@@ -576,7 +576,7 @@ void BeingNet::processBeingMove(Net::MessageIn &msg)
statusEffects & 0xffffU));
}
-void BeingNet::processBeingSpawn(Net::MessageIn &msg)
+void BeingRecv::processBeingSpawn(Net::MessageIn &msg)
{
if (!actorManager)
return;
@@ -587,7 +587,7 @@ void BeingNet::processBeingSpawn(Net::MessageIn &msg)
// Information about a being in range
const BeingId id = msg.readBeingId("being id");
- Ea::BeingNet::mSpawnId = id;
+ Ea::BeingRecv::mSpawnId = id;
const BeingId spawnId = id;
int16_t speed = msg.readInt16("speed");
// if (visible)
@@ -672,16 +672,16 @@ void BeingNet::processBeingSpawn(Net::MessageIn &msg)
dstBeing->setGender(Being::intToGender(gender));
dstBeing->setHairColor(hairColor);
// Set these after the gender, as the sprites may be gender-specific
- Ea::BeingNet::setSprite(dstBeing, SPRITE_HAIR_COLOR, hairStyle * -1,
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_HAIR_COLOR, hairStyle * -1,
ItemDB::get(-hairStyle).getDyeColorsString(hairColor));
- Ea::BeingNet::setSprite(dstBeing, SPRITE_WEAPON, headBottom);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_HEAD_BOTTOM, headMid);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_CLOTHES_COLOR, headTop);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_HAIR, shoes);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_SHOES, gloves);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_BODY, weapon, "",
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_WEAPON, headBottom);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_HEAD_BOTTOM, headMid);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_CLOTHES_COLOR, headTop);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_HAIR, shoes);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_SHOES, gloves);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_BODY, weapon, "",
ItemColor_one, true);
-// Ea::BeingNet::setSprite(dstBeing, SPRITE_FLOOR, shield);
+// Ea::BeingRecv::setSprite(dstBeing, SPRITE_FLOOR, shield);
}
else if (dstBeing->getType() == ActorType::Npc
&& serverFeatures->haveNpcGender())
@@ -731,7 +731,7 @@ void BeingNet::processBeingSpawn(Net::MessageIn &msg)
statusEffects & 0xffffU));
}
-void BeingNet::processMapTypeProperty(Net::MessageIn &msg)
+void BeingRecv::processMapTypeProperty(Net::MessageIn &msg)
{
const int16_t type = msg.readInt16("type");
const int flags = msg.readInt32("flags");
@@ -750,7 +750,7 @@ void BeingNet::processMapTypeProperty(Net::MessageIn &msg)
}
}
-void BeingNet::processMapType(Net::MessageIn &msg)
+void BeingRecv::processMapType(Net::MessageIn &msg)
{
const int16_t type = msg.readInt16("type");
if (type == 19)
@@ -759,7 +759,7 @@ void BeingNet::processMapType(Net::MessageIn &msg)
UNIMPLIMENTEDPACKET;
}
-void BeingNet::processSkillCasting(Net::MessageIn &msg)
+void BeingRecv::processSkillCasting(Net::MessageIn &msg)
{
// +++ need use other parameters
@@ -793,12 +793,12 @@ void BeingNet::processSkillCasting(Net::MessageIn &msg)
}
}
-void BeingNet::processBeingStatusChange(Net::MessageIn &msg)
+void BeingRecv::processBeingStatusChange(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processBeingStatusChange")
+ BLOCK_START("BeingRecv::processBeingStatusChange")
if (!actorManager)
{
- BLOCK_END("BeingNet::processBeingStatusChange")
+ BLOCK_END("BeingRecv::processBeingStatusChange")
return;
}
@@ -816,15 +816,15 @@ void BeingNet::processBeingStatusChange(Net::MessageIn &msg)
Being *const dstBeing = actorManager->findBeing(id);
if (dstBeing)
dstBeing->setStatusEffect(status, flag);
- BLOCK_END("BeingNet::processBeingStatusChange")
+ BLOCK_END("BeingRecv::processBeingStatusChange")
}
-void BeingNet::processBeingStatusChange2(Net::MessageIn &msg)
+void BeingRecv::processBeingStatusChange2(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processBeingStatusChange")
+ BLOCK_START("BeingRecv::processBeingStatusChange")
if (!actorManager)
{
- BLOCK_END("BeingNet::processBeingStatusChange")
+ BLOCK_END("BeingRecv::processBeingStatusChange")
return;
}
@@ -841,15 +841,15 @@ void BeingNet::processBeingStatusChange2(Net::MessageIn &msg)
Being *const dstBeing = actorManager->findBeing(id);
if (dstBeing)
dstBeing->setStatusEffect(status, flag);
- BLOCK_END("BeingNet::processBeingStatusChange")
+ BLOCK_END("BeingRecv::processBeingStatusChange")
}
-void BeingNet::processBeingMove2(Net::MessageIn &msg)
+void BeingRecv::processBeingMove2(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processBeingMove2")
+ BLOCK_START("BeingRecv::processBeingMove2")
if (!actorManager)
{
- BLOCK_END("BeingNet::processBeingMove2")
+ BLOCK_END("BeingRecv::processBeingMove2")
return;
}
@@ -874,7 +874,7 @@ void BeingNet::processBeingMove2(Net::MessageIn &msg)
if (!dstBeing)
{
- BLOCK_END("BeingNet::processBeingMove2")
+ BLOCK_END("BeingRecv::processBeingMove2")
return;
}
@@ -885,15 +885,15 @@ void BeingNet::processBeingMove2(Net::MessageIn &msg)
dstBeing->setDestination(dstX, dstY);
if (dstBeing->getType() == ActorType::Player)
dstBeing->setMoveTime();
- BLOCK_END("BeingNet::processBeingMove2")
+ BLOCK_END("BeingRecv::processBeingMove2")
}
-void BeingNet::processBeingAction2(Net::MessageIn &msg)
+void BeingRecv::processBeingAction2(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processBeingAction2")
+ BLOCK_START("BeingRecv::processBeingAction2")
if (!actorManager)
{
- BLOCK_END("BeingNet::processBeingAction2")
+ BLOCK_END("BeingRecv::processBeingAction2")
return;
}
@@ -979,10 +979,10 @@ void BeingNet::processBeingAction2(Net::MessageIn &msg)
UNIMPLIMENTEDPACKET;
break;
}
- BLOCK_END("BeingNet::processBeingAction2")
+ BLOCK_END("BeingRecv::processBeingAction2")
}
-void BeingNet::processMonsterHp(Net::MessageIn &msg)
+void BeingRecv::processMonsterHp(Net::MessageIn &msg)
{
Being *const dstBeing = actorManager->findBeing(
msg.readBeingId("monster id"));
@@ -995,7 +995,7 @@ void BeingNet::processMonsterHp(Net::MessageIn &msg)
}
}
-void BeingNet::processSkillAutoCast(Net::MessageIn &msg)
+void BeingRecv::processSkillAutoCast(Net::MessageIn &msg)
{
const int id = msg.readInt16("skill id");
msg.readInt16("inf");
@@ -1013,7 +1013,7 @@ void BeingNet::processSkillAutoCast(Net::MessageIn &msg)
}
}
-void BeingNet::processRanksList(Net::MessageIn &msg)
+void BeingRecv::processRanksList(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
// +++ here need window with rank tables.
@@ -1025,7 +1025,7 @@ void BeingNet::processRanksList(Net::MessageIn &msg)
msg.readInt32("my points");
}
-void BeingNet::processBlacksmithRanksList(Net::MessageIn &msg)
+void BeingRecv::processBlacksmithRanksList(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
// +++ here need window with rank tables.
@@ -1035,7 +1035,7 @@ void BeingNet::processBlacksmithRanksList(Net::MessageIn &msg)
msg.readInt32("points");
}
-void BeingNet::processAlchemistRanksList(Net::MessageIn &msg)
+void BeingRecv::processAlchemistRanksList(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
// +++ here need window with rank tables.
@@ -1045,7 +1045,7 @@ void BeingNet::processAlchemistRanksList(Net::MessageIn &msg)
msg.readInt32("points");
}
-void BeingNet::processTaekwonRanksList(Net::MessageIn &msg)
+void BeingRecv::processTaekwonRanksList(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
// +++ here need window with rank tables.
@@ -1055,7 +1055,7 @@ void BeingNet::processTaekwonRanksList(Net::MessageIn &msg)
msg.readInt32("points");
}
-void BeingNet::processPkRanksList(Net::MessageIn &msg)
+void BeingRecv::processPkRanksList(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
// +++ here need window with rank tables.
@@ -1065,12 +1065,12 @@ void BeingNet::processPkRanksList(Net::MessageIn &msg)
msg.readInt32("points");
}
-void BeingNet::processBeingChangeDirection(Net::MessageIn &msg)
+void BeingRecv::processBeingChangeDirection(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processBeingChangeDirection")
+ BLOCK_START("BeingRecv::processBeingChangeDirection")
if (!actorManager)
{
- BLOCK_END("BeingNet::processBeingChangeDirection")
+ BLOCK_END("BeingRecv::processBeingChangeDirection")
return;
}
@@ -1084,17 +1084,17 @@ void BeingNet::processBeingChangeDirection(Net::MessageIn &msg)
if (!dstBeing)
{
- BLOCK_END("BeingNet::processBeingChangeDirection")
+ BLOCK_END("BeingRecv::processBeingChangeDirection")
return;
}
dstBeing->setDirection(dir);
if (localPlayer)
localPlayer->imitateDirection(dstBeing, dir);
- BLOCK_END("BeingNet::processBeingChangeDirection")
+ BLOCK_END("BeingRecv::processBeingChangeDirection")
}
-void BeingNet::processBeingSpecialEffect(Net::MessageIn &msg)
+void BeingRecv::processBeingSpecialEffect(Net::MessageIn &msg)
{
if (!effectManager || !actorManager)
return;
@@ -1117,7 +1117,7 @@ void BeingNet::processBeingSpecialEffect(Net::MessageIn &msg)
}
}
-void BeingNet::processBeingSpecialEffectNum(Net::MessageIn &msg)
+void BeingRecv::processBeingSpecialEffectNum(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
// +++ need somhow show this effects.
@@ -1127,7 +1127,7 @@ void BeingNet::processBeingSpecialEffectNum(Net::MessageIn &msg)
msg.readInt32("num"); // effect variable
}
-void BeingNet::processBeingSoundEffect(Net::MessageIn &msg)
+void BeingRecv::processBeingSoundEffect(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
// +++ need play this effect.
@@ -1137,7 +1137,7 @@ void BeingNet::processBeingSoundEffect(Net::MessageIn &msg)
msg.readInt32("source being id");
}
-void BeingNet::processSkillGroundNoDamage(Net::MessageIn &msg)
+void BeingRecv::processSkillGroundNoDamage(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
msg.readInt16("skill id");
@@ -1148,7 +1148,7 @@ void BeingNet::processSkillGroundNoDamage(Net::MessageIn &msg)
msg.readInt32("tick");
}
-void BeingNet::processSkillEntry(Net::MessageIn &msg)
+void BeingRecv::processSkillEntry(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
msg.readInt16("len");
@@ -1162,12 +1162,12 @@ void BeingNet::processSkillEntry(Net::MessageIn &msg)
msg.readUInt8("level");
}
-void BeingNet::processPlaterStatusChange(Net::MessageIn &msg)
+void BeingRecv::processPlaterStatusChange(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processPlayerStop")
+ BLOCK_START("BeingRecv::processPlayerStop")
if (!actorManager)
{
- BLOCK_END("BeingNet::processPlayerStop")
+ BLOCK_END("BeingRecv::processPlayerStop")
return;
}
@@ -1187,10 +1187,10 @@ void BeingNet::processPlaterStatusChange(Net::MessageIn &msg)
(statusEffects >> 16) & 0xffff));
dstBeing->setStatusEffectBlock(16, static_cast<uint16_t>(
statusEffects & 0xffff));
- BLOCK_END("BeingNet::processPlayerStop")
+ BLOCK_END("BeingRecv::processPlayerStop")
}
-void BeingNet::processPlaterStatusChange2(Net::MessageIn &msg)
+void BeingRecv::processPlaterStatusChange2(Net::MessageIn &msg)
{
if (!actorManager)
return;
@@ -1210,7 +1210,7 @@ void BeingNet::processPlaterStatusChange2(Net::MessageIn &msg)
statusEffects & 0xffff));
}
-void BeingNet::processPlaterStatusChangeNoTick(Net::MessageIn &msg)
+void BeingRecv::processPlaterStatusChangeNoTick(Net::MessageIn &msg)
{
const uint16_t status = msg.readInt16("index");
const BeingId id = msg.readBeingId("account id");
@@ -1224,12 +1224,12 @@ void BeingNet::processPlaterStatusChangeNoTick(Net::MessageIn &msg)
dstBeing->setStatusEffect(status, flag);
}
-void BeingNet::processBeingResurrect(Net::MessageIn &msg)
+void BeingRecv::processBeingResurrect(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processBeingResurrect")
+ BLOCK_START("BeingRecv::processBeingResurrect")
if (!actorManager || !localPlayer)
{
- BLOCK_END("BeingNet::processBeingResurrect")
+ BLOCK_END("BeingRecv::processBeingResurrect")
return;
}
@@ -1240,7 +1240,7 @@ void BeingNet::processBeingResurrect(Net::MessageIn &msg)
Being *const dstBeing = actorManager->findBeing(id);
if (!dstBeing)
{
- BLOCK_END("BeingNet::processBeingResurrect")
+ BLOCK_END("BeingRecv::processBeingResurrect")
return;
}
@@ -1249,15 +1249,15 @@ void BeingNet::processBeingResurrect(Net::MessageIn &msg)
localPlayer->stopAttack();
dstBeing->setAction(BeingAction::STAND, 0);
- BLOCK_END("BeingNet::processBeingResurrect")
+ BLOCK_END("BeingRecv::processBeingResurrect")
}
-void BeingNet::processPlayerGuilPartyInfo(Net::MessageIn &msg)
+void BeingRecv::processPlayerGuilPartyInfo(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processPlayerGuilPartyInfo")
+ BLOCK_START("BeingRecv::processPlayerGuilPartyInfo")
if (!actorManager)
{
- BLOCK_END("BeingNet::processPlayerGuilPartyInfo")
+ BLOCK_END("BeingRecv::processPlayerGuilPartyInfo")
return;
}
@@ -1272,17 +1272,17 @@ void BeingNet::processPlayerGuilPartyInfo(Net::MessageIn &msg)
dstBeing->setGuildPos(msg.readString(24, "guild pos"));
dstBeing->addToCache();
}
- BLOCK_END("BeingNet::processPlayerGuilPartyInfo")
+ BLOCK_END("BeingRecv::processPlayerGuilPartyInfo")
}
-void BeingNet::processBeingRemoveSkil(Net::MessageIn &msg)
+void BeingRecv::processBeingRemoveSkil(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
// +++ if skill unit was added, here need remove it from actors
msg.readInt32("skill unit id");
}
-void BeingNet::processBeingFakeName(Net::MessageIn &msg)
+void BeingRecv::processBeingFakeName(Net::MessageIn &msg)
{
const BeingType::BeingType type = static_cast<BeingType::BeingType>(
msg.readUInt8("object type"));
@@ -1305,7 +1305,7 @@ void BeingNet::processBeingFakeName(Net::MessageIn &msg)
dstBeing->setDirection(dir);
}
-void BeingNet::processBeingStatUpdate1(Net::MessageIn &msg)
+void BeingRecv::processBeingStatUpdate1(Net::MessageIn &msg)
{
const BeingId id = msg.readBeingId("account id");
const int type = msg.readInt16("type");
@@ -1323,12 +1323,12 @@ void BeingNet::processBeingStatUpdate1(Net::MessageIn &msg)
dstBeing->setManner(value);
}
-void BeingNet::processBeingSelfEffect(Net::MessageIn &msg)
+void BeingRecv::processBeingSelfEffect(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processBeingSelfEffect")
+ BLOCK_START("BeingRecv::processBeingSelfEffect")
if (!effectManager || !actorManager)
{
- BLOCK_END("BeingNet::processBeingSelfEffect")
+ BLOCK_END("BeingRecv::processBeingSelfEffect")
return;
}
@@ -1336,7 +1336,7 @@ void BeingNet::processBeingSelfEffect(Net::MessageIn &msg)
Being *const being = actorManager->findBeing(id);
if (!being)
{
- BLOCK_END("BeingNet::processBeingSelfEffect")
+ BLOCK_END("BeingRecv::processBeingSelfEffect")
return;
}
@@ -1344,10 +1344,10 @@ void BeingNet::processBeingSelfEffect(Net::MessageIn &msg)
if (Particle::enabled)
effectManager->trigger(effectType, being);
- BLOCK_END("BeingNet::processBeingSelfEffect")
+ BLOCK_END("BeingRecv::processBeingSelfEffect")
}
-void BeingNet::processMobInfo(Net::MessageIn &msg)
+void BeingRecv::processMobInfo(Net::MessageIn &msg)
{
const int len = msg.readInt16("len");
if (len < 12)
@@ -1359,7 +1359,7 @@ void BeingNet::processMobInfo(Net::MessageIn &msg)
dstBeing->setAttackRange(attackRange);
}
-void BeingNet::processBeingAttrs(Net::MessageIn &msg)
+void BeingRecv::processBeingAttrs(Net::MessageIn &msg)
{
const int len = msg.readInt16("len");
if (len < 12)
@@ -1382,7 +1382,7 @@ void BeingNet::processBeingAttrs(Net::MessageIn &msg)
}
}
-void BeingNet::processMonsterInfo(Net::MessageIn &msg)
+void BeingRecv::processMonsterInfo(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
@@ -1396,7 +1396,7 @@ void BeingNet::processMonsterInfo(Net::MessageIn &msg)
msg.readInt16("ele");
}
-void BeingNet::processClassChange(Net::MessageIn &msg)
+void BeingRecv::processClassChange(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
@@ -1405,7 +1405,7 @@ void BeingNet::processClassChange(Net::MessageIn &msg)
msg.readInt32("class");
}
-void BeingNet::processSpiritBalls(Net::MessageIn &msg)
+void BeingRecv::processSpiritBalls(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
@@ -1413,7 +1413,7 @@ void BeingNet::processSpiritBalls(Net::MessageIn &msg)
msg.readInt16("spirits amount");
}
-void BeingNet::processSpiritBallSingle(Net::MessageIn &msg)
+void BeingRecv::processSpiritBallSingle(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
@@ -1421,7 +1421,7 @@ void BeingNet::processSpiritBallSingle(Net::MessageIn &msg)
msg.readInt16("spirits amount");
}
-void BeingNet::processBladeStop(Net::MessageIn &msg)
+void BeingRecv::processBladeStop(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
@@ -1430,7 +1430,7 @@ void BeingNet::processBladeStop(Net::MessageIn &msg)
msg.readInt32("flag");
}
-void BeingNet::processComboDelay(Net::MessageIn &msg)
+void BeingRecv::processComboDelay(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
@@ -1438,14 +1438,14 @@ void BeingNet::processComboDelay(Net::MessageIn &msg)
msg.readInt32("wait");
}
-void BeingNet::processWddingEffect(Net::MessageIn &msg)
+void BeingRecv::processWddingEffect(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
msg.readBeingId("being id");
}
-void BeingNet::processBeingSlide(Net::MessageIn &msg)
+void BeingRecv::processBeingSlide(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
@@ -1454,7 +1454,7 @@ void BeingNet::processBeingSlide(Net::MessageIn &msg)
msg.readInt16("y");
}
-void BeingNet::processStarsKill(Net::MessageIn &msg)
+void BeingRecv::processStarsKill(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
@@ -1464,14 +1464,14 @@ void BeingNet::processStarsKill(Net::MessageIn &msg)
msg.readUInt8("result");
}
-void BeingNet::processGladiatorFeelRequest(Net::MessageIn &msg)
+void BeingRecv::processGladiatorFeelRequest(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
msg.readUInt8("which");
}
-void BeingNet::processBossMapInfo(Net::MessageIn &msg)
+void BeingRecv::processBossMapInfo(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
@@ -1485,7 +1485,7 @@ void BeingNet::processBossMapInfo(Net::MessageIn &msg)
msg.readString(24, "monster name"); // really can be used 51 byte?
}
-void BeingNet::processBeingFont(Net::MessageIn &msg)
+void BeingRecv::processBeingFont(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
@@ -1493,7 +1493,7 @@ void BeingNet::processBeingFont(Net::MessageIn &msg)
msg.readInt16("font");
}
-void BeingNet::processBeingMilleniumShield(Net::MessageIn &msg)
+void BeingRecv::processBeingMilleniumShield(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
@@ -1502,7 +1502,7 @@ void BeingNet::processBeingMilleniumShield(Net::MessageIn &msg)
msg.readInt16("unused");
}
-void BeingNet::processBeingCharm(Net::MessageIn &msg)
+void BeingRecv::processBeingCharm(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
@@ -1511,7 +1511,7 @@ void BeingNet::processBeingCharm(Net::MessageIn &msg)
msg.readInt16("charm count");
}
-void BeingNet::processBeingViewEquipment(Net::MessageIn &msg)
+void BeingRecv::processBeingViewEquipment(Net::MessageIn &msg)
{
UNIMPLIMENTEDPACKET;
@@ -1543,9 +1543,9 @@ void BeingNet::processBeingViewEquipment(Net::MessageIn &msg)
}
}
-void BeingNet::processPvpSet(Net::MessageIn &msg)
+void BeingRecv::processPvpSet(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processPvpSet")
+ BLOCK_START("BeingRecv::processPvpSet")
const BeingId id = msg.readBeingId("being id");
const int rank = msg.readInt32("rank");
msg.readInt32("num");
@@ -1555,15 +1555,15 @@ void BeingNet::processPvpSet(Net::MessageIn &msg)
if (dstBeing)
dstBeing->setPvpRank(rank);
}
- BLOCK_END("BeingNet::processPvpSet")
+ BLOCK_END("BeingRecv::processPvpSet")
}
-void BeingNet::processNameResponse2(Net::MessageIn &msg)
+void BeingRecv::processNameResponse2(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processNameResponse2")
+ BLOCK_START("BeingRecv::processNameResponse2")
if (!actorManager || !localPlayer)
{
- BLOCK_END("BeingNet::processNameResponse2")
+ BLOCK_END("BeingRecv::processNameResponse2")
return;
}
@@ -1601,13 +1601,13 @@ void BeingNet::processNameResponse2(Net::MessageIn &msg)
}
}
}
- BLOCK_END("BeingNet::processNameResponse2")
+ BLOCK_END("BeingRecv::processNameResponse2")
}
-Being *BeingNet::createBeing2(Net::MessageIn &msg,
- const BeingId id,
- const int16_t job,
- const BeingType::BeingType beingType)
+Being *BeingRecv::createBeing2(Net::MessageIn &msg,
+ const BeingId id,
+ const int16_t job,
+ const BeingType::BeingType beingType)
{
if (!actorManager)
return nullptr;
diff --git a/src/net/eathena/beingnet.h b/src/net/eathena/beingrecv.h
index 0b3dd041f..137143143 100644
--- a/src/net/eathena/beingnet.h
+++ b/src/net/eathena/beingrecv.h
@@ -30,7 +30,7 @@
namespace EAthena
{
- namespace BeingNet
+ namespace BeingRecv
{
void processBeingChangeLook2(Net::MessageIn &msg);
void processBeingChangeLookCards(Net::MessageIn &msg);
@@ -95,7 +95,7 @@ namespace EAthena
const BeingId id,
const int16_t job,
const BeingType::BeingType beingType);
- } // namespace Being
+ } // namespace BeingRecv
} // namespace EAthena
#endif // NET_EATHENA_BEING_H
diff --git a/src/net/tmwa/beinghandler.cpp b/src/net/tmwa/beinghandler.cpp
index 2ec3e62cb..d8287205f 100644
--- a/src/net/tmwa/beinghandler.cpp
+++ b/src/net/tmwa/beinghandler.cpp
@@ -38,9 +38,9 @@
#include "net/serverfeatures.h"
-#include "net/ea/beingnet.h"
+#include "net/ea/beingrecv.h"
-#include "net/tmwa/beingnet.h"
+#include "net/tmwa/beingrecv.h"
#include "net/tmwa/guildmanager.h"
#include "net/tmwa/messageout.h"
#include "net/tmwa/protocol.h"
@@ -115,122 +115,122 @@ void BeingHandler::handleMessage(Net::MessageIn &msg)
switch (msg.getId())
{
case SMSG_BEING_VISIBLE:
- BeingNet::processBeingVisible(msg);
+ BeingRecv::processBeingVisible(msg);
break;
case SMSG_BEING_MOVE:
- BeingNet::processBeingMove(msg);
+ BeingRecv::processBeingMove(msg);
break;
case SMSG_BEING_MOVE2:
- BeingNet::processBeingMove2(msg);
+ BeingRecv::processBeingMove2(msg);
break;
case SMSG_BEING_MOVE3:
- Ea::BeingNet::processBeingMove3(msg);
+ Ea::BeingRecv::processBeingMove3(msg);
break;
case SMSG_BEING_SPAWN:
- BeingNet::processBeingSpawn(msg);
+ BeingRecv::processBeingSpawn(msg);
break;
case SMSG_BEING_REMOVE:
- Ea::BeingNet::processBeingRemove(msg);
+ Ea::BeingRecv::processBeingRemove(msg);
break;
case SMSG_BEING_RESURRECT:
- BeingNet::processBeingResurrect(msg);
+ BeingRecv::processBeingResurrect(msg);
break;
case SMSG_SKILL_DAMAGE:
- Ea::BeingNet::processSkillDamage(msg);
+ Ea::BeingRecv::processSkillDamage(msg);
break;
case SMSG_BEING_ACTION:
- Ea::BeingNet::processBeingAction(msg);
+ Ea::BeingRecv::processBeingAction(msg);
break;
case SMSG_BEING_SELFEFFECT:
- BeingNet::processBeingSelfEffect(msg);
+ BeingRecv::processBeingSelfEffect(msg);
break;
case SMSG_BEING_EMOTION:
- Ea::BeingNet::processBeingEmotion(msg);
+ Ea::BeingRecv::processBeingEmotion(msg);
break;
case SMSG_BEING_CHANGE_LOOKS:
- BeingNet::processBeingChangeLook(msg);
+ BeingRecv::processBeingChangeLook(msg);
break;
case SMSG_BEING_CHANGE_LOOKS2:
- BeingNet::processBeingChangeLook2(msg);
+ BeingRecv::processBeingChangeLook2(msg);
break;
case SMSG_BEING_NAME_RESPONSE:
- Ea::BeingNet::processNameResponse(msg);
+ Ea::BeingRecv::processNameResponse(msg);
break;
case SMSG_BEING_IP_RESPONSE:
- BeingNet::processIpResponse(msg);
+ BeingRecv::processIpResponse(msg);
break;
case SMSG_SOLVE_CHAR_NAME:
break;
case SMSG_PLAYER_GUILD_PARTY_INFO:
- BeingNet::processPlayerGuilPartyInfo(msg);
+ BeingRecv::processPlayerGuilPartyInfo(msg);
break;
case SMSG_BEING_CHANGE_DIRECTION:
- BeingNet::processBeingChangeDirection(msg);
+ BeingRecv::processBeingChangeDirection(msg);
break;
case SMSG_PLAYER_UPDATE_1:
- BeingNet::processPlayerUpdate1(msg);
+ BeingRecv::processPlayerUpdate1(msg);
break;
case SMSG_PLAYER_UPDATE_2:
- BeingNet::processPlayerUpdate2(msg);
+ BeingRecv::processPlayerUpdate2(msg);
break;
case SMSG_PLAYER_MOVE:
- BeingNet::processPlayerMove(msg);
+ BeingRecv::processPlayerMove(msg);
break;
case SMSG_PLAYER_STOP:
- Ea::BeingNet::processPlayerStop(msg);
+ Ea::BeingRecv::processPlayerStop(msg);
break;
case SMSG_PLAYER_MOVE_TO_ATTACK:
- Ea::BeingNet::processPlayerMoveToAttack(msg);
+ Ea::BeingRecv::processPlayerMoveToAttack(msg);
break;
case SMSG_PLAYER_STATUS_CHANGE:
- BeingNet::processPlaterStatusChange(msg);
+ BeingRecv::processPlaterStatusChange(msg);
break;
case SMSG_BEING_STATUS_CHANGE:
- BeingNet::processBeingStatusChange(msg);
+ BeingRecv::processBeingStatusChange(msg);
break;
case SMSG_SKILL_CASTING:
- BeingNet::processSkillCasting(msg);
+ BeingRecv::processSkillCasting(msg);
break;
case SMSG_SKILL_CAST_CANCEL:
- BeingNet::processSkillCastCancel(msg);
+ BeingRecv::processSkillCastCancel(msg);
break;
case SMSG_SKILL_NO_DAMAGE:
- Ea::BeingNet::processSkillNoDamage(msg);
+ Ea::BeingRecv::processSkillNoDamage(msg);
break;
case SMSG_PVP_MAP_MODE:
- Ea::BeingNet::processPvpMapMode(msg);
+ Ea::BeingRecv::processPvpMapMode(msg);
break;
case SMSG_PVP_SET:
- BeingNet::processPvpSet(msg);
+ BeingRecv::processPvpSet(msg);
break;
default:
diff --git a/src/net/tmwa/beingnet.cpp b/src/net/tmwa/beingrecv.cpp
index 0230e053d..6e326ea65 100644
--- a/src/net/tmwa/beingnet.cpp
+++ b/src/net/tmwa/beingrecv.cpp
@@ -20,7 +20,7 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-#include "net/tmwa/beingnet.h"
+#include "net/tmwa/beingrecv.h"
#include "actormanager.h"
#include "effectmanager.h"
@@ -38,7 +38,7 @@
#include "net/serverfeatures.h"
-#include "net/ea/beingnet.h"
+#include "net/ea/beingrecv.h"
#include "net/tmwa/guildmanager.h"
#include "net/tmwa/messageout.h"
@@ -59,12 +59,12 @@ extern int serverVersion;
namespace TmwAthena
{
-void BeingNet::processBeingChangeLook(Net::MessageIn &msg)
+void BeingRecv::processBeingChangeLook(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processBeingChangeLook")
+ BLOCK_START("BeingRecv::processBeingChangeLook")
if (!actorManager)
{
- BLOCK_END("BeingNet::processBeingChangeLook")
+ BLOCK_END("BeingRecv::processBeingChangeLook")
return;
}
@@ -77,19 +77,19 @@ void BeingNet::processBeingChangeLook(Net::MessageIn &msg)
if (!localPlayer || !dstBeing)
{
- BLOCK_END("BeingNet::processBeingChangeLook")
+ BLOCK_END("BeingRecv::processBeingChangeLook")
return;
}
processBeingChangeLookContinue(msg, dstBeing, type, id, id2);
- BLOCK_END("BeingNet::processBeingChangeLook")
+ BLOCK_END("BeingRecv::processBeingChangeLook")
}
-void BeingNet::processBeingChangeLook2(Net::MessageIn &msg)
+void BeingRecv::processBeingChangeLook2(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processBeingChangeLook")
+ BLOCK_START("BeingRecv::processBeingChangeLook")
if (!actorManager)
{
- BLOCK_END("BeingNet::processBeingChangeLook")
+ BLOCK_END("BeingRecv::processBeingChangeLook")
return;
}
@@ -112,18 +112,18 @@ void BeingNet::processBeingChangeLook2(Net::MessageIn &msg)
if (!localPlayer || !dstBeing)
{
- BLOCK_END("BeingNet::processBeingChangeLook")
+ BLOCK_END("BeingRecv::processBeingChangeLook")
return;
}
processBeingChangeLookContinue(msg, dstBeing, type, id, id2);
- BLOCK_END("BeingNet::processBeingChangeLook")
+ BLOCK_END("BeingRecv::processBeingChangeLook")
}
-void BeingNet::processBeingChangeLookContinue(Net::MessageIn &msg,
- Being *const dstBeing,
- const uint8_t type,
- const int id,
- const int id2)
+void BeingRecv::processBeingChangeLookContinue(Net::MessageIn &msg,
+ Being *const dstBeing,
+ const uint8_t type,
+ const int id,
+ const int id2)
{
if (dstBeing->getType() == ActorType::Player)
dstBeing->setOtherTime();
@@ -219,12 +219,12 @@ void BeingNet::processBeingChangeLookContinue(Net::MessageIn &msg,
}
}
-void BeingNet::processPlayerUpdate1(Net::MessageIn &msg)
+void BeingRecv::processPlayerUpdate1(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processPlayerMoveUpdate")
+ BLOCK_START("BeingRecv::processPlayerMoveUpdate")
if (!actorManager || !localPlayer)
{
- BLOCK_END("BeingNet::processPlayerMoveUpdate")
+ BLOCK_END("BeingRecv::processPlayerMoveUpdate")
return;
}
@@ -245,15 +245,15 @@ void BeingNet::processPlayerUpdate1(Net::MessageIn &msg)
{
if (actorManager->isBlocked(id) == true)
{
- BLOCK_END("BeingNet::processPlayerMoveUpdate")
+ BLOCK_END("BeingRecv::processPlayerMoveUpdate")
return;
}
- dstBeing = Ea::BeingNet::createBeing(id, job);
+ dstBeing = Ea::BeingRecv::createBeing(id, job);
if (!dstBeing)
{
- BLOCK_END("BeingNet::processPlayerMoveUpdate")
+ BLOCK_END("BeingRecv::processPlayerMoveUpdate")
return;
}
}
@@ -352,15 +352,15 @@ void BeingNet::processPlayerUpdate1(Net::MessageIn &msg)
dstBeing->setStatusEffectBlock(16, static_cast<uint16_t>(
statusEffects & 0xffff));
- BLOCK_END("BeingNet::processPlayerMoveUpdate")
+ BLOCK_END("BeingRecv::processPlayerMoveUpdate")
}
-void BeingNet::processPlayerUpdate2(Net::MessageIn &msg)
+void BeingRecv::processPlayerUpdate2(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processPlayerMoveUpdate")
+ BLOCK_START("BeingRecv::processPlayerMoveUpdate")
if (!actorManager || !localPlayer)
{
- BLOCK_END("BeingNet::processPlayerMoveUpdate")
+ BLOCK_END("BeingRecv::processPlayerMoveUpdate")
return;
}
@@ -381,15 +381,15 @@ void BeingNet::processPlayerUpdate2(Net::MessageIn &msg)
{
if (actorManager->isBlocked(id) == true)
{
- BLOCK_END("BeingNet::processPlayerMoveUpdate")
+ BLOCK_END("BeingRecv::processPlayerMoveUpdate")
return;
}
- dstBeing = Ea::BeingNet::createBeing(id, job);
+ dstBeing = Ea::BeingRecv::createBeing(id, job);
if (!dstBeing)
{
- BLOCK_END("BeingNet::processPlayerMoveUpdate")
+ BLOCK_END("BeingRecv::processPlayerMoveUpdate")
return;
}
}
@@ -484,15 +484,15 @@ void BeingNet::processPlayerUpdate2(Net::MessageIn &msg)
dstBeing->setStatusEffectBlock(16, static_cast<uint16_t>(
statusEffects & 0xffff));
- BLOCK_END("BeingNet::processPlayerMoveUpdate")
+ BLOCK_END("BeingRecv::processPlayerMoveUpdate")
}
-void BeingNet::processPlayerMove(Net::MessageIn &msg)
+void BeingRecv::processPlayerMove(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processPlayerMoveUpdate")
+ BLOCK_START("BeingRecv::processPlayerMoveUpdate")
if (!actorManager || !localPlayer)
{
- BLOCK_END("BeingNet::processPlayerMoveUpdate")
+ BLOCK_END("BeingRecv::processPlayerMoveUpdate")
return;
}
@@ -513,15 +513,15 @@ void BeingNet::processPlayerMove(Net::MessageIn &msg)
{
if (actorManager->isBlocked(id) == true)
{
- BLOCK_END("BeingNet::processPlayerMoveUpdate")
+ BLOCK_END("BeingRecv::processPlayerMoveUpdate")
return;
}
- dstBeing = Ea::BeingNet::createBeing(id, job);
+ dstBeing = Ea::BeingRecv::createBeing(id, job);
if (!dstBeing)
{
- BLOCK_END("BeingNet::processPlayerMoveUpdate")
+ BLOCK_END("BeingRecv::processPlayerMoveUpdate")
return;
}
}
@@ -646,15 +646,15 @@ void BeingNet::processPlayerMove(Net::MessageIn &msg)
if (dstBeing->getType() == ActorType::Player)
dstBeing->setMoveTime();
- BLOCK_END("BeingNet::processPlayerMoveUpdate")
+ BLOCK_END("BeingRecv::processPlayerMoveUpdate")
}
-void BeingNet::processBeingVisible(Net::MessageIn &msg)
+void BeingRecv::processBeingVisible(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processBeingVisibleOrMove")
+ BLOCK_START("BeingRecv::processBeingVisibleOrMove")
if (!actorManager)
{
- BLOCK_END("BeingNet::processBeingVisibleOrMove")
+ BLOCK_END("BeingRecv::processBeingVisibleOrMove")
return;
}
@@ -662,11 +662,11 @@ void BeingNet::processBeingVisible(Net::MessageIn &msg)
// Information about a being in range
const BeingId id = msg.readBeingId("being id");
- if (id == Ea::BeingNet::mSpawnId)
- spawnId = Ea::BeingNet::mSpawnId;
+ if (id == Ea::BeingRecv::mSpawnId)
+ spawnId = Ea::BeingRecv::mSpawnId;
else
spawnId = BeingId_zero;
- Ea::BeingNet::mSpawnId = BeingId_zero;
+ Ea::BeingRecv::mSpawnId = BeingId_zero;
int16_t speed = msg.readInt16("speed");
const uint16_t stunMode = msg.readInt16("opt1");
uint32_t statusEffects = msg.readInt16("opt2");
@@ -692,21 +692,21 @@ void BeingNet::processBeingVisible(Net::MessageIn &msg)
// known as ghosts, so don't create those.
if (job == 0 && toInt(id, int) >= 110000000)
{
- BLOCK_END("BeingNet::processBeingVisibleOrMove")
+ BLOCK_END("BeingRecv::processBeingVisibleOrMove")
return;
}
if (actorManager->isBlocked(id) == true)
{
- BLOCK_END("BeingNet::processBeingVisibleOrMove")
+ BLOCK_END("BeingRecv::processBeingVisibleOrMove")
return;
}
- dstBeing = Ea::BeingNet::createBeing(id, job);
+ dstBeing = Ea::BeingRecv::createBeing(id, job);
if (!dstBeing)
{
- BLOCK_END("BeingNet::processBeingVisibleOrMove")
+ BLOCK_END("BeingRecv::processBeingVisibleOrMove")
return;
}
}
@@ -804,17 +804,17 @@ void BeingNet::processBeingVisible(Net::MessageIn &msg)
gender &= 3;
dstBeing->setGender(Being::intToGender(gender));
// Set these after the gender, as the sprites may be gender-specific
- Ea::BeingNet::setSprite(dstBeing, SPRITE_HAIR_COLOR, hairStyle * -1,
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_HAIR_COLOR, hairStyle * -1,
ItemDB::get(-hairStyle).getDyeColorsString(hairColor));
dstBeing->setHairColor(hairColor);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_WEAPON, headBottom);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_HEAD_BOTTOM, headMid);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_CLOTHES_COLOR, headTop);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_HAIR, shoes);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_SHOES, gloves);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_BODY, weapon, "",
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_WEAPON, headBottom);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_HEAD_BOTTOM, headMid);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_CLOTHES_COLOR, headTop);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_HAIR, shoes);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_SHOES, gloves);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_BODY, weapon, "",
ItemColor_one, true);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_FLOOR, shield);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_FLOOR, shield);
}
else if (dstBeing->getType() == ActorType::Npc
&& serverFeatures->haveNpcGender())
@@ -854,15 +854,15 @@ void BeingNet::processBeingVisible(Net::MessageIn &msg)
(statusEffects >> 16) & 0xffff));
dstBeing->setStatusEffectBlock(16, static_cast<uint16_t>(
statusEffects & 0xffff));
- BLOCK_END("BeingNet::processBeingVisibleOrMove")
+ BLOCK_END("BeingRecv::processBeingVisibleOrMove")
}
-void BeingNet::processBeingMove(Net::MessageIn &msg)
+void BeingRecv::processBeingMove(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processBeingVisibleOrMove")
+ BLOCK_START("BeingRecv::processBeingVisibleOrMove")
if (!actorManager)
{
- BLOCK_END("BeingNet::processBeingVisibleOrMove")
+ BLOCK_END("BeingRecv::processBeingVisibleOrMove")
return;
}
@@ -870,11 +870,11 @@ void BeingNet::processBeingMove(Net::MessageIn &msg)
// Information about a being in range
const BeingId id = msg.readBeingId("being id");
- if (id == Ea::BeingNet::mSpawnId)
- spawnId = Ea::BeingNet::mSpawnId;
+ if (id == Ea::BeingRecv::mSpawnId)
+ spawnId = Ea::BeingRecv::mSpawnId;
else
spawnId = BeingId_zero;
- Ea::BeingNet::mSpawnId = BeingId_zero;
+ Ea::BeingRecv::mSpawnId = BeingId_zero;
int16_t speed = msg.readInt16("speed");
const uint16_t stunMode = msg.readInt16("opt1");
uint32_t statusEffects = msg.readInt16("opt2");
@@ -900,21 +900,21 @@ void BeingNet::processBeingMove(Net::MessageIn &msg)
// known as ghosts, so don't create those.
if (job == 0 && toInt(id, int) >= 110000000)
{
- BLOCK_END("BeingNet::processBeingVisibleOrMove")
+ BLOCK_END("BeingRecv::processBeingVisibleOrMove")
return;
}
if (actorManager->isBlocked(id) == true)
{
- BLOCK_END("BeingNet::processBeingVisibleOrMove")
+ BLOCK_END("BeingRecv::processBeingVisibleOrMove")
return;
}
- dstBeing = Ea::BeingNet::createBeing(id, job);
+ dstBeing = Ea::BeingRecv::createBeing(id, job);
if (!dstBeing)
{
- BLOCK_END("BeingNet::processBeingVisibleOrMove")
+ BLOCK_END("BeingRecv::processBeingVisibleOrMove")
return;
}
}
@@ -1007,17 +1007,17 @@ void BeingNet::processBeingMove(Net::MessageIn &msg)
gender &= 3;
dstBeing->setGender(Being::intToGender(gender));
// Set these after the gender, as the sprites may be gender-specific
- Ea::BeingNet::setSprite(dstBeing, SPRITE_HAIR_COLOR, hairStyle * -1,
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_HAIR_COLOR, hairStyle * -1,
ItemDB::get(-hairStyle).getDyeColorsString(hairColor));
dstBeing->setHairColor(hairColor);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_WEAPON, headBottom);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_HEAD_BOTTOM, headMid);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_CLOTHES_COLOR, headTop);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_HAIR, shoes);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_SHOES, gloves);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_BODY, weapon, "",
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_WEAPON, headBottom);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_HEAD_BOTTOM, headMid);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_CLOTHES_COLOR, headTop);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_HAIR, shoes);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_SHOES, gloves);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_BODY, weapon, "",
ItemColor_one, true);
- Ea::BeingNet::setSprite(dstBeing, SPRITE_FLOOR, shield);
+ Ea::BeingRecv::setSprite(dstBeing, SPRITE_FLOOR, shield);
}
else if (dstBeing->getType() == ActorType::Npc
&& serverFeatures->haveNpcGender())
@@ -1046,24 +1046,24 @@ void BeingNet::processBeingMove(Net::MessageIn &msg)
(statusEffects >> 16) & 0xffff));
dstBeing->setStatusEffectBlock(16, static_cast<uint16_t>(
statusEffects & 0xffff));
- BLOCK_END("BeingNet::processBeingVisibleOrMove")
+ BLOCK_END("BeingRecv::processBeingVisibleOrMove")
}
-void BeingNet::processBeingSpawn(Net::MessageIn &msg)
+void BeingRecv::processBeingSpawn(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processBeingSpawn")
+ BLOCK_START("BeingRecv::processBeingSpawn")
// skipping this packet
- Ea::BeingNet::mSpawnId = msg.readBeingId("being id");
+ Ea::BeingRecv::mSpawnId = msg.readBeingId("being id");
msg.readInt16("speed");
msg.readInt16("opt1");
msg.readInt16("opt2");
msg.readInt16("option");
msg.readInt16("disguise");
msg.skip(25, "unused");
- BLOCK_END("BeingNet::processBeingSpawn")
+ BLOCK_END("BeingRecv::processBeingSpawn")
}
-void BeingNet::processSkillCasting(Net::MessageIn &msg)
+void BeingRecv::processSkillCasting(Net::MessageIn &msg)
{
msg.readInt32("src id");
msg.readInt32("dst id");
@@ -1074,12 +1074,12 @@ void BeingNet::processSkillCasting(Net::MessageIn &msg)
msg.readInt32("cast time");
}
-void BeingNet::processBeingStatusChange(Net::MessageIn &msg)
+void BeingRecv::processBeingStatusChange(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processBeingStatusChange")
+ BLOCK_START("BeingRecv::processBeingStatusChange")
if (!actorManager)
{
- BLOCK_END("BeingNet::processBeingStatusChange")
+ BLOCK_END("BeingRecv::processBeingStatusChange")
return;
}
@@ -1092,15 +1092,15 @@ void BeingNet::processBeingStatusChange(Net::MessageIn &msg)
Being *const dstBeing = actorManager->findBeing(id);
if (dstBeing)
dstBeing->setStatusEffect(status, flag);
- BLOCK_END("BeingNet::processBeingStatusChange")
+ BLOCK_END("BeingRecv::processBeingStatusChange")
}
-void BeingNet::processBeingMove2(Net::MessageIn &msg)
+void BeingRecv::processBeingMove2(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processBeingMove2")
+ BLOCK_START("BeingRecv::processBeingMove2")
if (!actorManager)
{
- BLOCK_END("BeingNet::processBeingMove2")
+ BLOCK_END("BeingRecv::processBeingMove2")
return;
}
@@ -1120,7 +1120,7 @@ void BeingNet::processBeingMove2(Net::MessageIn &msg)
if (!dstBeing)
{
- BLOCK_END("BeingNet::processBeingMove2")
+ BLOCK_END("BeingRecv::processBeingMove2")
return;
}
@@ -1133,15 +1133,15 @@ void BeingNet::processBeingMove2(Net::MessageIn &msg)
dstBeing->setDestination(dstX, dstY);
if (dstBeing->getType() == ActorType::Player)
dstBeing->setMoveTime();
- BLOCK_END("BeingNet::processBeingMove2")
+ BLOCK_END("BeingRecv::processBeingMove2")
}
-void BeingNet::processBeingChangeDirection(Net::MessageIn &msg)
+void BeingRecv::processBeingChangeDirection(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processBeingChangeDirection")
+ BLOCK_START("BeingRecv::processBeingChangeDirection")
if (!actorManager)
{
- BLOCK_END("BeingNet::processBeingChangeDirection")
+ BLOCK_END("BeingRecv::processBeingChangeDirection")
return;
}
@@ -1152,7 +1152,7 @@ void BeingNet::processBeingChangeDirection(Net::MessageIn &msg)
{
msg.readInt16("unused");
msg.readUInt8("direction");
- BLOCK_END("BeingNet::processBeingChangeDirection");
+ BLOCK_END("BeingRecv::processBeingChangeDirection");
return;
}
@@ -1163,15 +1163,15 @@ void BeingNet::processBeingChangeDirection(Net::MessageIn &msg)
dstBeing->setDirection(dir);
if (localPlayer)
localPlayer->imitateDirection(dstBeing, dir);
- BLOCK_END("BeingNet::processBeingChangeDirection")
+ BLOCK_END("BeingRecv::processBeingChangeDirection")
}
-void BeingNet::processPlaterStatusChange(Net::MessageIn &msg)
+void BeingRecv::processPlaterStatusChange(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processPlayerStop")
+ BLOCK_START("BeingRecv::processPlayerStop")
if (!actorManager)
{
- BLOCK_END("BeingNet::processPlayerStop")
+ BLOCK_END("BeingRecv::processPlayerStop")
return;
}
@@ -1191,15 +1191,15 @@ void BeingNet::processPlaterStatusChange(Net::MessageIn &msg)
(statusEffects >> 16) & 0xffff));
dstBeing->setStatusEffectBlock(16, static_cast<uint16_t>(
statusEffects & 0xffff));
- BLOCK_END("BeingNet::processPlayerStop")
+ BLOCK_END("BeingRecv::processPlayerStop")
}
-void BeingNet::processBeingResurrect(Net::MessageIn &msg)
+void BeingRecv::processBeingResurrect(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processBeingResurrect")
+ BLOCK_START("BeingRecv::processBeingResurrect")
if (!actorManager || !localPlayer)
{
- BLOCK_END("BeingNet::processBeingResurrect")
+ BLOCK_END("BeingRecv::processBeingResurrect")
return;
}
@@ -1209,7 +1209,7 @@ void BeingNet::processBeingResurrect(Net::MessageIn &msg)
Being *const dstBeing = actorManager->findBeing(id);
if (!dstBeing)
{
- BLOCK_END("BeingNet::processBeingResurrect")
+ BLOCK_END("BeingRecv::processBeingResurrect")
return;
}
@@ -1219,15 +1219,15 @@ void BeingNet::processBeingResurrect(Net::MessageIn &msg)
if (msg.readUInt8("flag?") == 1U)
dstBeing->setAction(BeingAction::STAND, 0);
- BLOCK_END("BeingNet::processBeingResurrect")
+ BLOCK_END("BeingRecv::processBeingResurrect")
}
-void BeingNet::processPlayerGuilPartyInfo(Net::MessageIn &msg)
+void BeingRecv::processPlayerGuilPartyInfo(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processPlayerGuilPartyInfo")
+ BLOCK_START("BeingRecv::processPlayerGuilPartyInfo")
if (!actorManager)
{
- BLOCK_END("BeingNet::processPlayerGuilPartyInfo")
+ BLOCK_END("BeingRecv::processPlayerGuilPartyInfo")
return;
}
@@ -1257,15 +1257,15 @@ void BeingNet::processPlayerGuilPartyInfo(Net::MessageIn &msg)
msg.readString(24, "guild pos");
msg.readString(24, "?");
}
- BLOCK_END("BeingNet::processPlayerGuilPartyInfo")
+ BLOCK_END("BeingRecv::processPlayerGuilPartyInfo")
}
-void BeingNet::processBeingSelfEffect(Net::MessageIn &msg)
+void BeingRecv::processBeingSelfEffect(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processBeingSelfEffect")
+ BLOCK_START("BeingRecv::processBeingSelfEffect")
if (!effectManager || !actorManager)
{
- BLOCK_END("BeingNet::processBeingSelfEffect")
+ BLOCK_END("BeingRecv::processBeingSelfEffect")
return;
}
@@ -1273,7 +1273,7 @@ void BeingNet::processBeingSelfEffect(Net::MessageIn &msg)
Being *const being = actorManager->findBeing(id);
if (!being)
{
- BLOCK_END("BeingNet::processBeingSelfEffect")
+ BLOCK_END("BeingRecv::processBeingSelfEffect")
return;
}
@@ -1288,20 +1288,20 @@ void BeingNet::processBeingSelfEffect(Net::MessageIn &msg)
{ // reset received damage
socialWindow->resetDamage(being->getName());
}
- BLOCK_END("BeingNet::processBeingSelfEffect")
+ BLOCK_END("BeingRecv::processBeingSelfEffect")
}
-void BeingNet::processSkillCastCancel(Net::MessageIn &msg)
+void BeingRecv::processSkillCastCancel(Net::MessageIn &msg)
{
msg.readInt32("skill id");
}
-void BeingNet::processIpResponse(Net::MessageIn &msg)
+void BeingRecv::processIpResponse(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processIpResponse")
+ BLOCK_START("BeingRecv::processIpResponse")
if (!actorManager)
{
- BLOCK_END("BeingNet::processIpResponse")
+ BLOCK_END("BeingRecv::processIpResponse")
return;
}
@@ -1309,12 +1309,12 @@ void BeingNet::processIpResponse(Net::MessageIn &msg)
msg.readBeingId("being id"));
if (dstBeing)
dstBeing->setIp(ipToString(msg.readInt32("ip address")));
- BLOCK_END("BeingNet::processIpResponse")
+ BLOCK_END("BeingRecv::processIpResponse")
}
-void BeingNet::processPvpSet(Net::MessageIn &msg)
+void BeingRecv::processPvpSet(Net::MessageIn &msg)
{
- BLOCK_START("BeingNet::processPvpSet")
+ BLOCK_START("BeingRecv::processPvpSet")
const BeingId id = msg.readBeingId("being id");
const int rank = msg.readInt32("rank");
int teamId = 0;
@@ -1332,12 +1332,12 @@ void BeingNet::processPvpSet(Net::MessageIn &msg)
dstBeing->addToCache();
}
}
- BLOCK_END("BeingNet::processPvpSet")
+ BLOCK_END("BeingRecv::processPvpSet")
}
-void BeingNet::applyPlayerAction(Net::MessageIn &msg,
- Being *const being,
- const uint8_t type)
+void BeingRecv::applyPlayerAction(Net::MessageIn &msg,
+ Being *const being,
+ const uint8_t type)
{
if (!being)
return;
@@ -1367,7 +1367,8 @@ void BeingNet::applyPlayerAction(Net::MessageIn &msg,
}
}
-void BeingNet::setServerGender(Being *const being, const uint8_t gender)
+void BeingRecv::setServerGender(Being *const being,
+ const uint8_t gender)
{
if (!being)
return;
diff --git a/src/net/tmwa/beingnet.h b/src/net/tmwa/beingrecv.h
index 268cc0723..9bc660b4f 100644
--- a/src/net/tmwa/beingnet.h
+++ b/src/net/tmwa/beingrecv.h
@@ -29,7 +29,7 @@
namespace TmwAthena
{
- namespace BeingNet
+ namespace BeingRecv
{
void processBeingChangeLook(Net::MessageIn &msg);
void processBeingChangeLook2(Net::MessageIn &msg);
@@ -60,7 +60,7 @@ namespace TmwAthena
const uint8_t type);
void setServerGender(Being *const being,
const uint8_t gender);
- } // namespace Being
+ } // namespace BeingRecv
} // namespace TmwAthena
#endif // NET_TMWA_BEING_H