summaryrefslogtreecommitdiff
path: root/src/net
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-09-10 23:58:39 +0300
committerAndrei Karas <akaras@inbox.ru>2014-09-10 23:58:39 +0300
commit0a39e956218ca15bf78803f89141c7c9dfcec0d9 (patch)
treeadfc0fcd42792ddad6b3cb8843d6fe0c22170580 /src/net
parent69022cd939e572feadaadf1041ae7dadad782ed6 (diff)
downloadplus-0a39e956218ca15bf78803f89141c7c9dfcec0d9.tar.gz
plus-0a39e956218ca15bf78803f89141c7c9dfcec0d9.tar.bz2
plus-0a39e956218ca15bf78803f89141c7c9dfcec0d9.tar.xz
plus-0a39e956218ca15bf78803f89141c7c9dfcec0d9.zip
Change format in ActorType enum.
Diffstat (limited to 'src/net')
-rw-r--r--src/net/ea/beinghandler.cpp26
-rw-r--r--src/net/ea/chathandler.cpp4
-rw-r--r--src/net/ea/guildhandler.cpp6
-rw-r--r--src/net/ea/partyhandler.cpp4
-rw-r--r--src/net/eathena/beinghandler.cpp54
-rw-r--r--src/net/eathena/guildhandler.cpp2
-rw-r--r--src/net/eathena/partyhandler.cpp4
-rw-r--r--src/net/tmwa/beinghandler.cpp42
-rw-r--r--src/net/tmwa/guildhandler.cpp2
-rw-r--r--src/net/tmwa/partyhandler.cpp2
10 files changed, 73 insertions, 73 deletions
diff --git a/src/net/ea/beinghandler.cpp b/src/net/ea/beinghandler.cpp
index 8bb5ec20f..a94f686da 100644
--- a/src/net/ea/beinghandler.cpp
+++ b/src/net/ea/beinghandler.cpp
@@ -59,15 +59,15 @@ Being *BeingHandler::createBeing(const int id, const int16_t job) const
if (!actorManager)
return nullptr;
- ActorType::Type type = ActorType::UNKNOWN;
+ ActorType::Type type = ActorType::Unknown;
if (job <= 25 || (job >= 4001 && job <= 4049))
- type = ActorType::PLAYER;
+ type = ActorType::Player;
else if (job >= 46 && job <= 1000)
- type = ActorType::NPC;
+ type = ActorType::Npc;
else if (job > 1000 && job <= 2000)
- type = ActorType::MONSTER;
+ type = ActorType::Monster;
else if (job == 45)
- type = ActorType::PORTAL;
+ type = ActorType::Portal;
Being *const being = actorManager->createBeing(id, type, job);
return being;
@@ -123,7 +123,7 @@ void BeingHandler::processBeingRemove(Net::MessageIn &msg) const
}
else
{
- if (dstBeing->getType() == ActorType::PLAYER)
+ if (dstBeing->getType() == ActorType::Player)
{
if (botCheckerWindow)
botCheckerWindow->updateList();
@@ -222,11 +222,11 @@ void BeingHandler::processBeingAction(Net::MessageIn &msg) const
case Being::FLEE: // Lucky Dodge
if (srcBeing)
{
- if (srcSpeed && srcBeing->getType() == ActorType::PLAYER)
+ if (srcSpeed && srcBeing->getType() == ActorType::Player)
srcBeing->setAttackDelay(srcSpeed);
// attackid=1, type
srcBeing->handleAttack(dstBeing, param1, 1);
- if (srcBeing->getType() == ActorType::PLAYER)
+ if (srcBeing->getType() == ActorType::Player)
srcBeing->setAttackTime();
}
if (dstBeing)
@@ -246,7 +246,7 @@ void BeingHandler::processBeingAction(Net::MessageIn &msg) const
if (srcBeing)
{
srcBeing->setAction(BeingAction::SIT, 0);
- if (srcBeing->getType() == ActorType::PLAYER)
+ if (srcBeing->getType() == ActorType::Player)
{
srcBeing->setMoveTime();
if (localPlayer)
@@ -259,7 +259,7 @@ void BeingHandler::processBeingAction(Net::MessageIn &msg) const
if (srcBeing)
{
srcBeing->setAction(BeingAction::STAND, 0);
- if (srcBeing->getType() == ActorType::PLAYER)
+ if (srcBeing->getType() == ActorType::Player)
{
srcBeing->setMoveTime();
if (localPlayer)
@@ -305,7 +305,7 @@ void BeingHandler::processBeingSelfEffect(Net::MessageIn &msg) const
effectManager->trigger(effectType, being);
// +++ need dehard code effectType == 3
- if (effectType == 3 && being->getType() == ActorType::PLAYER
+ if (effectType == 3 && being->getType() == ActorType::Player
&& socialWindow)
{ // reset received damage
socialWindow->resetDamage(being->getName());
@@ -338,7 +338,7 @@ void BeingHandler::processBeingEmotion(Net::MessageIn &msg) const
localPlayer->imitateEmote(dstBeing, emote);
}
}
- if (dstBeing->getType() == ActorType::PLAYER)
+ if (dstBeing->getType() == ActorType::Player)
dstBeing->setOtherTime();
BLOCK_END("BeingHandler::processBeingEmotion")
}
@@ -367,7 +367,7 @@ void BeingHandler::processNameResponse(Net::MessageIn &msg) const
dstBeing->updateGuild();
dstBeing->addToCache();
- if (dstBeing->getType() == ActorType::PLAYER)
+ if (dstBeing->getType() == ActorType::Player)
dstBeing->updateColors();
if (localPlayer)
diff --git a/src/net/ea/chathandler.cpp b/src/net/ea/chathandler.cpp
index 4bec39513..62c6b17f8 100644
--- a/src/net/ea/chathandler.cpp
+++ b/src/net/ea/chathandler.cpp
@@ -295,7 +295,7 @@ void ChatHandler::processBeingChat(Net::MessageIn &msg) const
std::string chatMsg = msg.readRawString(chatMsgLength, "message");
- if (being->getType() == ActorType::PLAYER)
+ if (being->getType() == ActorType::Player)
being->setTalkTime();
const size_t pos = chatMsg.find(" : ", 0);
@@ -310,7 +310,7 @@ void ChatHandler::processBeingChat(Net::MessageIn &msg) const
sender_name = "?";
}
else if (sender_name != being->getName()
- && being->getType() == ActorType::PLAYER)
+ && being->getType() == ActorType::Player)
{
if (!being->getName().empty())
sender_name = being->getName();
diff --git a/src/net/ea/guildhandler.cpp b/src/net/ea/guildhandler.cpp
index de1d2763c..598811fdd 100644
--- a/src/net/ea/guildhandler.cpp
+++ b/src/net/ea/guildhandler.cpp
@@ -279,7 +279,7 @@ void GuildHandler::processGuildMemberList(Net::MessageIn &msg) const
if (actorManager)
{
Being *const being = actorManager->findBeingByName(
- name, ActorType::PLAYER);
+ name, ActorType::Player);
if (being)
{
being->setGuildName(taGuild->getName());
@@ -481,7 +481,7 @@ void GuildHandler::processGuildLeave(Net::MessageIn &msg) const
if (actorManager)
{
Being *const b = actorManager->findBeingByName(
- nick, ActorType::PLAYER);
+ nick, ActorType::Player);
if (b)
b->clearGuilds();
@@ -524,7 +524,7 @@ void GuildHandler::processGuildExpulsion(Net::MessageIn &msg) const
if (actorManager)
{
Being *const b = actorManager->findBeingByName(
- nick, ActorType::PLAYER);
+ nick, ActorType::Player);
if (b)
b->clearGuilds();
diff --git a/src/net/ea/partyhandler.cpp b/src/net/ea/partyhandler.cpp
index c048178f8..b1d6845f5 100644
--- a/src/net/ea/partyhandler.cpp
+++ b/src/net/ea/partyhandler.cpp
@@ -92,7 +92,7 @@ void PartyHandler::processPartyInvited(Net::MessageIn &msg) const
const Being *const being = actorManager->findBeing(id);
if (being)
{
- if (being->getType() == ActorType::PLAYER)
+ if (being->getType() == ActorType::Player)
nick = being->getName();
}
}
@@ -214,7 +214,7 @@ void PartyHandler::processPartyLeave(Net::MessageIn &msg) const
if (actorManager)
{
Being *const b = actorManager->findBeing(id);
- if (b && b->getType() == ActorType::PLAYER)
+ if (b && b->getType() == ActorType::Player)
{
b->setParty(nullptr);
b->setPartyName("");
diff --git a/src/net/eathena/beinghandler.cpp b/src/net/eathena/beinghandler.cpp
index fb0a94f64..7f00dc9de 100644
--- a/src/net/eathena/beinghandler.cpp
+++ b/src/net/eathena/beinghandler.cpp
@@ -319,7 +319,7 @@ void BeingHandler::processBeingChangeLookContinue(Being *const dstBeing,
const int id,
const int id2) const
{
- if (dstBeing->getType() == ActorType::PLAYER)
+ if (dstBeing->getType() == ActorType::Player)
dstBeing->setOtherTime();
const std::string color;
@@ -432,7 +432,7 @@ void BeingHandler::processNameResponse2(Net::MessageIn &msg)
dstBeing->updateGuild();
dstBeing->addToCache();
- if (dstBeing->getType() == ActorType::PLAYER)
+ if (dstBeing->getType() == ActorType::Player)
dstBeing->updateColors();
if (localPlayer)
@@ -841,7 +841,7 @@ void BeingHandler::processPlayerMove(Net::MessageIn &msg) const
msg.readUInt8("unknown");
- if (dstBeing->getType() != ActorType::PLAYER)
+ if (dstBeing->getType() != ActorType::Player)
dstBeing->setActionTime(tick_time);
dstBeing->setStunMode(stunMode);
@@ -850,7 +850,7 @@ void BeingHandler::processPlayerMove(Net::MessageIn &msg) const
dstBeing->setStatusEffectBlock(16, static_cast<uint16_t>(
statusEffects & 0xffffU));
- if (dstBeing->getType() == ActorType::PLAYER)
+ if (dstBeing->getType() == ActorType::Player)
dstBeing->setMoveTime();
}
@@ -881,7 +881,7 @@ void BeingHandler::processBeingVisible(Net::MessageIn &msg)
Being *dstBeing = actorManager->findBeing(id);
- if (dstBeing && dstBeing->getType() == ActorType::MONSTER
+ if (dstBeing && dstBeing->getType() == ActorType::Monster
&& !dstBeing->isAlive())
{
actorManager->destroy(dstBeing);
@@ -910,11 +910,11 @@ void BeingHandler::processBeingVisible(Net::MessageIn &msg)
else
{
// undeleting marked for deletion being
- if (dstBeing->getType() == ActorType::NPC)
+ if (dstBeing->getType() == ActorType::Npc)
actorManager->undelete(dstBeing);
}
- if (dstBeing->getType() == ActorType::PLAYER)
+ if (dstBeing->getType() == ActorType::Player)
dstBeing->setMoveTime();
if (spawnId)
@@ -934,7 +934,7 @@ void BeingHandler::processBeingVisible(Net::MessageIn &msg)
dstBeing->setWalkSpeed(Vector(speed, speed, 0));
dstBeing->setSubtype(job, 0);
- if (dstBeing->getType() == ActorType::MONSTER && localPlayer)
+ if (dstBeing->getType() == ActorType::Monster && localPlayer)
localPlayer->checkNewName(dstBeing);
const int hairStyle = msg.readInt16("hair style");
@@ -956,7 +956,7 @@ void BeingHandler::processBeingVisible(Net::MessageIn &msg)
msg.readUInt8("karma");
uint8_t gender = msg.readUInt8("gender");
- if (dstBeing->getType() == ActorType::PLAYER)
+ if (dstBeing->getType() == ActorType::Player)
{
gender &= 3;
dstBeing->setGender(Being::intToGender(gender));
@@ -972,7 +972,7 @@ void BeingHandler::processBeingVisible(Net::MessageIn &msg)
// if (!mHideShield)
// setSprite(dstBeing, SPRITE_SHIELD, shield);
}
- else if (dstBeing->getType() == ActorType::NPC)
+ else if (dstBeing->getType() == ActorType::Npc)
{
setServerGender(dstBeing, gender);
}
@@ -1050,7 +1050,7 @@ void BeingHandler::processBeingMove(Net::MessageIn &msg)
Being *dstBeing = actorManager->findBeing(id);
- if (dstBeing && dstBeing->getType() == ActorType::MONSTER
+ if (dstBeing && dstBeing->getType() == ActorType::Monster
&& !dstBeing->isAlive())
{
actorManager->destroy(dstBeing);
@@ -1079,11 +1079,11 @@ void BeingHandler::processBeingMove(Net::MessageIn &msg)
else
{
// undeleting marked for deletion being
- if (dstBeing->getType() == ActorType::NPC)
+ if (dstBeing->getType() == ActorType::Npc)
actorManager->undelete(dstBeing);
}
- if (dstBeing->getType() == ActorType::PLAYER)
+ if (dstBeing->getType() == ActorType::Player)
dstBeing->setMoveTime();
if (spawnId)
@@ -1095,7 +1095,7 @@ void BeingHandler::processBeingMove(Net::MessageIn &msg)
dstBeing->setWalkSpeed(Vector(speed, speed, 0));
dstBeing->setSubtype(job, 0);
- if (dstBeing->getType() == ActorType::MONSTER && localPlayer)
+ if (dstBeing->getType() == ActorType::Monster && localPlayer)
localPlayer->checkNewName(dstBeing);
const int hairStyle = msg.readInt16("hair style");
@@ -1119,7 +1119,7 @@ void BeingHandler::processBeingMove(Net::MessageIn &msg)
msg.readUInt8("karma");
uint8_t gender = msg.readUInt8("gender");
- if (dstBeing->getType() == ActorType::PLAYER)
+ if (dstBeing->getType() == ActorType::Player)
{
gender &= 3;
dstBeing->setGender(Being::intToGender(gender));
@@ -1135,7 +1135,7 @@ void BeingHandler::processBeingMove(Net::MessageIn &msg)
// if (!mHideShield)
// setSprite(dstBeing, SPRITE_SHIELD, shield);
}
- else if (dstBeing->getType() == ActorType::NPC)
+ else if (dstBeing->getType() == ActorType::Npc)
{
setServerGender(dstBeing, gender);
}
@@ -1215,7 +1215,7 @@ void BeingHandler::processBeingSpawn(Net::MessageIn &msg)
Being *dstBeing = actorManager->findBeing(id);
- if (dstBeing && dstBeing->getType() == ActorType::MONSTER
+ if (dstBeing && dstBeing->getType() == ActorType::Monster
&& !dstBeing->isAlive())
{
actorManager->destroy(dstBeing);
@@ -1244,11 +1244,11 @@ void BeingHandler::processBeingSpawn(Net::MessageIn &msg)
else
{
// undeleting marked for deletion being
- if (dstBeing->getType() == ActorType::NPC)
+ if (dstBeing->getType() == ActorType::Npc)
actorManager->undelete(dstBeing);
}
- if (dstBeing->getType() == ActorType::PLAYER)
+ if (dstBeing->getType() == ActorType::Player)
dstBeing->setMoveTime();
if (spawnId)
@@ -1262,7 +1262,7 @@ void BeingHandler::processBeingSpawn(Net::MessageIn &msg)
dstBeing->setWalkSpeed(Vector(speed, speed, 0));
dstBeing->setSubtype(job, 0);
- if (dstBeing->getType() == ActorType::MONSTER && localPlayer)
+ if (dstBeing->getType() == ActorType::Monster && localPlayer)
localPlayer->checkNewName(dstBeing);
const int hairStyle = msg.readInt16("hair style");
@@ -1284,7 +1284,7 @@ void BeingHandler::processBeingSpawn(Net::MessageIn &msg)
msg.readUInt8("karma");
uint8_t gender = msg.readUInt8("gender");
- if (dstBeing->getType() == ActorType::PLAYER)
+ if (dstBeing->getType() == ActorType::Player)
{
gender &= 3;
dstBeing->setGender(Being::intToGender(gender));
@@ -1300,7 +1300,7 @@ void BeingHandler::processBeingSpawn(Net::MessageIn &msg)
// if (!mHideShield)
// setSprite(dstBeing, SPRITE_SHIELD, shield);
}
- else if (dstBeing->getType() == ActorType::NPC)
+ else if (dstBeing->getType() == ActorType::Npc)
{
setServerGender(dstBeing, gender);
}
@@ -1425,7 +1425,7 @@ void BeingHandler::processBeingMove2(Net::MessageIn &msg) const
dstBeing->setAction(BeingAction::STAND, 0);
dstBeing->setTileCoords(srcX, srcY);
dstBeing->setDestination(dstX, dstY);
- if (dstBeing->getType() == ActorType::PLAYER)
+ if (dstBeing->getType() == ActorType::Player)
dstBeing->setMoveTime();
BLOCK_END("BeingHandler::processBeingMove2")
}
@@ -1461,11 +1461,11 @@ void BeingHandler::processBeingAction2(Net::MessageIn &msg) const
case Being::FLEE: // Lucky Dodge
if (srcBeing)
{
- if (srcSpeed && srcBeing->getType() == ActorType::PLAYER)
+ if (srcSpeed && srcBeing->getType() == ActorType::Player)
srcBeing->setAttackDelay(srcSpeed);
// attackid=1, type
srcBeing->handleAttack(dstBeing, param1, 1);
- if (srcBeing->getType() == ActorType::PLAYER)
+ if (srcBeing->getType() == ActorType::Player)
srcBeing->setAttackTime();
}
if (dstBeing)
@@ -1485,7 +1485,7 @@ void BeingHandler::processBeingAction2(Net::MessageIn &msg) const
if (srcBeing)
{
srcBeing->setAction(BeingAction::SIT, 0);
- if (srcBeing->getType() == ActorType::PLAYER)
+ if (srcBeing->getType() == ActorType::Player)
{
srcBeing->setMoveTime();
if (localPlayer)
@@ -1498,7 +1498,7 @@ void BeingHandler::processBeingAction2(Net::MessageIn &msg) const
if (srcBeing)
{
srcBeing->setAction(BeingAction::STAND, 0);
- if (srcBeing->getType() == ActorType::PLAYER)
+ if (srcBeing->getType() == ActorType::Player)
{
srcBeing->setMoveTime();
if (localPlayer)
diff --git a/src/net/eathena/guildhandler.cpp b/src/net/eathena/guildhandler.cpp
index a4e604803..10fba3be8 100644
--- a/src/net/eathena/guildhandler.cpp
+++ b/src/net/eathena/guildhandler.cpp
@@ -206,7 +206,7 @@ void GuildHandler::invite(const int guildId A_UNUSED,
return;
const Being *const being = actorManager->findBeingByName(
- name, ActorType::PLAYER);
+ name, ActorType::Player);
if (being)
{
MessageOut msg(CMSG_GUILD_INVITE);
diff --git a/src/net/eathena/partyhandler.cpp b/src/net/eathena/partyhandler.cpp
index 182ea4957..5ef628744 100644
--- a/src/net/eathena/partyhandler.cpp
+++ b/src/net/eathena/partyhandler.cpp
@@ -130,7 +130,7 @@ void PartyHandler::invite(const std::string &name) const
return;
const Being *const being = actorManager->findBeingByName(
- name, ActorType::PLAYER);
+ name, ActorType::Player);
if (being)
{
MessageOut outMsg(CMSG_PARTY_INVITE);
@@ -448,7 +448,7 @@ void PartyHandler::processPartyInviteResponse(Net::MessageIn &msg) const
void PartyHandler::changeLeader(const std::string &name) const
{
const Being *const being = actorManager->findBeingByName(
- name, ActorType::PLAYER);
+ name, ActorType::Player);
if (!being)
return;
MessageOut outMsg(CMSG_PARTY_CHANGE_LEADER);
diff --git a/src/net/tmwa/beinghandler.cpp b/src/net/tmwa/beinghandler.cpp
index ee431acbe..195579946 100644
--- a/src/net/tmwa/beinghandler.cpp
+++ b/src/net/tmwa/beinghandler.cpp
@@ -319,7 +319,7 @@ void BeingHandler::processBeingChangeLookContinue(Being *const dstBeing,
const int id,
const int id2) const
{
- if (dstBeing->getType() == ActorType::PLAYER)
+ if (dstBeing->getType() == ActorType::Player)
dstBeing->setOtherTime();
const std::string color;
@@ -444,7 +444,7 @@ void BeingHandler::processNameResponse2(Net::MessageIn &msg)
dstBeing->updateGuild();
dstBeing->addToCache();
- if (dstBeing->getType() == ActorType::PLAYER)
+ if (dstBeing->getType() == ActorType::Player)
dstBeing->updateColors();
if (localPlayer)
@@ -929,7 +929,7 @@ void BeingHandler::processPlayerMove(Net::MessageIn &msg) const
msg.readUInt8("unused");
- if (dstBeing->getType() != ActorType::PLAYER)
+ if (dstBeing->getType() != ActorType::Player)
dstBeing->setActionTime(tick_time);
dstBeing->setStunMode(stunMode);
@@ -938,7 +938,7 @@ void BeingHandler::processPlayerMove(Net::MessageIn &msg) const
dstBeing->setStatusEffectBlock(16, static_cast<uint16_t>(
statusEffects & 0xffff));
- if (dstBeing->getType() == ActorType::PLAYER)
+ if (dstBeing->getType() == ActorType::Player)
dstBeing->setMoveTime();
BLOCK_END("BeingHandler::processPlayerMoveUpdate")
}
@@ -1020,7 +1020,7 @@ void BeingHandler::processBeingVisible(Net::MessageIn &msg)
Being *dstBeing = actorManager->findBeing(id);
- if (dstBeing && dstBeing->getType() == ActorType::MONSTER
+ if (dstBeing && dstBeing->getType() == ActorType::Monster
&& !dstBeing->isAlive())
{
actorManager->destroy(dstBeing);
@@ -1057,7 +1057,7 @@ void BeingHandler::processBeingVisible(Net::MessageIn &msg)
}
else
{
- if (dstBeing->getType() == ActorType::NPC)
+ if (dstBeing->getType() == ActorType::Npc)
{
actorManager->undelete(dstBeing);
if (serverVersion < 1)
@@ -1065,7 +1065,7 @@ void BeingHandler::processBeingVisible(Net::MessageIn &msg)
}
}
- if (dstBeing->getType() == ActorType::PLAYER)
+ if (dstBeing->getType() == ActorType::Player)
dstBeing->setMoveTime();
if (spawnId)
@@ -1086,7 +1086,7 @@ void BeingHandler::processBeingVisible(Net::MessageIn &msg)
const uint8_t hairStyle = msg.readUInt8("hair style");
const uint8_t look = msg.readUInt8("look");
dstBeing->setSubtype(job, look);
- if (dstBeing->getType() == ActorType::MONSTER && localPlayer)
+ if (dstBeing->getType() == ActorType::Monster && localPlayer)
localPlayer->checkNewName(dstBeing);
dstBeing->setWalkSpeed(Vector(speed, speed, 0));
const uint16_t weapon = msg.readInt16("weapon");
@@ -1100,7 +1100,7 @@ void BeingHandler::processBeingVisible(Net::MessageIn &msg)
const uint16_t shoes = msg.readInt16("shoes / clothes color");
uint16_t gloves;
- if (dstBeing->getType() == ActorType::MONSTER)
+ if (dstBeing->getType() == ActorType::Monster)
{
if (serverVersion > 0 || tmwServerVersion >= 0x0E0701)
{
@@ -1130,7 +1130,7 @@ void BeingHandler::processBeingVisible(Net::MessageIn &msg)
msg.readInt16("manner");
dstBeing->setStatusEffectBlock(32, msg.readInt16("opt3"));
- if (serverVersion > 0 && dstBeing->getType() == ActorType::MONSTER)
+ if (serverVersion > 0 && dstBeing->getType() == ActorType::Monster)
{
const int attackRange = static_cast<int>(
msg.readUInt8("attack range (was karma)"));
@@ -1142,7 +1142,7 @@ void BeingHandler::processBeingVisible(Net::MessageIn &msg)
}
uint8_t gender = msg.readUInt8("gender");
- if (!disguiseId && dstBeing->getType() == ActorType::PLAYER)
+ if (!disguiseId && dstBeing->getType() == ActorType::Player)
{
// reserving bits for future usage
gender &= 3;
@@ -1160,7 +1160,7 @@ void BeingHandler::processBeingVisible(Net::MessageIn &msg)
if (!mHideShield)
setSprite(dstBeing, SPRITE_SHIELD, shield);
}
- else if (dstBeing->getType() == ActorType::NPC)
+ else if (dstBeing->getType() == ActorType::Npc)
{
setServerGender(dstBeing, gender);
}
@@ -1229,7 +1229,7 @@ void BeingHandler::processBeingMove(Net::MessageIn &msg)
Being *dstBeing = actorManager->findBeing(id);
- if (dstBeing && dstBeing->getType() == ActorType::MONSTER
+ if (dstBeing && dstBeing->getType() == ActorType::Monster
&& !dstBeing->isAlive())
{
actorManager->destroy(dstBeing);
@@ -1266,7 +1266,7 @@ void BeingHandler::processBeingMove(Net::MessageIn &msg)
}
else
{
- if (dstBeing->getType() == ActorType::NPC)
+ if (dstBeing->getType() == ActorType::Npc)
{
actorManager->undelete(dstBeing);
if (serverVersion < 1)
@@ -1274,7 +1274,7 @@ void BeingHandler::processBeingMove(Net::MessageIn &msg)
}
}
- if (dstBeing->getType() == ActorType::PLAYER)
+ if (dstBeing->getType() == ActorType::Player)
dstBeing->setMoveTime();
if (spawnId)
@@ -1287,7 +1287,7 @@ void BeingHandler::processBeingMove(Net::MessageIn &msg)
const uint8_t hairStyle = msg.readUInt8("hair style");
const uint8_t look = msg.readUInt8("look");
dstBeing->setSubtype(job, look);
- if (dstBeing->getType() == ActorType::MONSTER && localPlayer)
+ if (dstBeing->getType() == ActorType::Monster && localPlayer)
localPlayer->checkNewName(dstBeing);
dstBeing->setWalkSpeed(Vector(speed, speed, 0));
const uint16_t weapon = msg.readInt16("weapon");
@@ -1303,7 +1303,7 @@ void BeingHandler::processBeingMove(Net::MessageIn &msg)
const uint16_t shoes = msg.readInt16("shoes / clothes color");
uint16_t gloves;
- if (dstBeing->getType() == ActorType::MONSTER)
+ if (dstBeing->getType() == ActorType::Monster)
{
if (serverVersion > 0 || tmwServerVersion >= 0x0E0701)
{
@@ -1333,7 +1333,7 @@ void BeingHandler::processBeingMove(Net::MessageIn &msg)
msg.readInt16("manner");
dstBeing->setStatusEffectBlock(32, msg.readInt16("opt3"));
- if (serverVersion > 0 && dstBeing->getType() == ActorType::MONSTER)
+ if (serverVersion > 0 && dstBeing->getType() == ActorType::Monster)
{
const int attackRange = static_cast<int>(
msg.readUInt8("attack range (was karma)"));
@@ -1345,7 +1345,7 @@ void BeingHandler::processBeingMove(Net::MessageIn &msg)
}
uint8_t gender = msg.readUInt8("gender");
- if (!disguiseId && dstBeing->getType() == ActorType::PLAYER)
+ if (!disguiseId && dstBeing->getType() == ActorType::Player)
{
// reserving bits for future usage
gender &= 3;
@@ -1363,7 +1363,7 @@ void BeingHandler::processBeingMove(Net::MessageIn &msg)
if (!mHideShield)
setSprite(dstBeing, SPRITE_SHIELD, shield);
}
- else if (dstBeing->getType() == ActorType::NPC)
+ else if (dstBeing->getType() == ActorType::Npc)
{
setServerGender(dstBeing, gender);
}
@@ -1472,7 +1472,7 @@ void BeingHandler::processBeingMove2(Net::MessageIn &msg) const
dstBeing->setAction(BeingAction::STAND, 0);
dstBeing->setTileCoords(srcX, srcY);
dstBeing->setDestination(dstX, dstY);
- if (dstBeing->getType() == ActorType::PLAYER)
+ if (dstBeing->getType() == ActorType::Player)
dstBeing->setMoveTime();
BLOCK_END("BeingHandler::processBeingMove2")
}
diff --git a/src/net/tmwa/guildhandler.cpp b/src/net/tmwa/guildhandler.cpp
index 5aa272475..852dfa135 100644
--- a/src/net/tmwa/guildhandler.cpp
+++ b/src/net/tmwa/guildhandler.cpp
@@ -212,7 +212,7 @@ void GuildHandler::invite(const int guildId A_UNUSED,
return;
const Being *const being = actorManager->findBeingByName(
- name, ActorType::PLAYER);
+ name, ActorType::Player);
if (being)
{
MessageOut msg(CMSG_GUILD_INVITE);
diff --git a/src/net/tmwa/partyhandler.cpp b/src/net/tmwa/partyhandler.cpp
index ba3a4d26c..0ae327edb 100644
--- a/src/net/tmwa/partyhandler.cpp
+++ b/src/net/tmwa/partyhandler.cpp
@@ -124,7 +124,7 @@ void PartyHandler::invite(const std::string &name) const
return;
const Being *const being = actorManager->findBeingByName(
- name, ActorType::PLAYER);
+ name, ActorType::Player);
if (being)
{
MessageOut outMsg(CMSG_PARTY_INVITE);