Fix copy and paste error

This commit is contained in:
Michael Cook (mackal) 2021-03-06 19:58:18 -05:00
parent e5f5db69b4
commit 29cdca380f

View File

@ -2271,7 +2271,7 @@ void NPC::PetOnSpawn(NewSpawn_Struct* ns)
if(client) if(client)
{ {
SetPetOwnerClient(true); SetPetOwnerClient(true);
std::string tmp_lastname = swarmOwner->GetName(); std::string tmp_lastname = client->GetName();
tmp_lastname += "'s Pet"; tmp_lastname += "'s Pet";
if (tmp_lastname.size() < sizeof(ns->spawn.lastName)) if (tmp_lastname.size() < sizeof(ns->spawn.lastName))
strn0cpy(ns->spawn.lastName, tmp_lastname.c_str(), sizeof(ns->spawn.lastName)); strn0cpy(ns->spawn.lastName, tmp_lastname.c_str(), sizeof(ns->spawn.lastName));