summaryrefslogtreecommitdiff
path: root/src/being
diff options
context:
space:
mode:
Diffstat (limited to 'src/being')
-rw-r--r--src/being/being.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/being/being.cpp b/src/being/being.cpp
index 5ba258bf5..39f241312 100644
--- a/src/being/being.cpp
+++ b/src/being/being.cpp
@@ -881,14 +881,17 @@ void Being::handleSkill(Being *const victim, const int damage,
void Being::setName(const std::string &name)
{
- if (mType == ActorType::Npc || mType == ActorType::Portal)
+ if (mType == ActorType::Npc)
{
mName = name.substr(0, name.find('#', 0));
showName();
}
else
{
- mName = name;
+ if (mType == ActorType::Portal)
+ mName = name.substr(0, name.find('#', 0));
+ else
+ mName = name;
if (getShowName())
showName();