From e661a35ac2c568db5a9b635169fb2d3d22af4e5d Mon Sep 17 00:00:00 2001 From: Koncord Date: Sun, 18 Sep 2016 11:51:32 +0800 Subject: [PATCH] Fix checking strings in SetName & SetBirthsign --- apps/openmw-mp/Script/Functions/Stats.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/apps/openmw-mp/Script/Functions/Stats.cpp b/apps/openmw-mp/Script/Functions/Stats.cpp index 5c74918e6..bced4b91f 100644 --- a/apps/openmw-mp/Script/Functions/Stats.cpp +++ b/apps/openmw-mp/Script/Functions/Stats.cpp @@ -20,10 +20,10 @@ void StatsFunctions::SetName(unsigned short pid, const char *name) noexcept Player *player; GET_PLAYER(pid, player,); - if (player->GetCell()->mName == name) + if (player->Npc()->mName == name) return; - player->GetCell()->mName = name; + player->Npc()->mName = name; } const char *StatsFunctions::GetName(unsigned short pid) noexcept @@ -40,7 +40,7 @@ void StatsFunctions::SetBirthsign(unsigned short pid, const char *sign) noexcept Player *player; GET_PLAYER(pid, player,); - if (player->GetCell()->mName == sign) + if (*player->BirthSign() == sign) return; *player->BirthSign() = sign;