diff --git a/src/UserInterface/Packet.h b/src/UserInterface/Packet.h index 7a5f4e8..51864d4 100644 --- a/src/UserInterface/Packet.h +++ b/src/UserInterface/Packet.h @@ -2281,6 +2281,7 @@ typedef struct SPacketGCNPCPosition struct TNPCPosition { uint8_t bType; + uint32_t dwVnum; char name[CHARACTER_NAME_MAX_LEN+1]; int32_t x; int32_t y; diff --git a/src/UserInterface/PythonNetworkStreamPhaseGame.cpp b/src/UserInterface/PythonNetworkStreamPhaseGame.cpp index deb133b..335201e 100644 --- a/src/UserInterface/PythonNetworkStreamPhaseGame.cpp +++ b/src/UserInterface/PythonNetworkStreamPhaseGame.cpp @@ -4173,7 +4173,15 @@ bool CPythonNetworkStream::RecvNPCList() if (!Recv(sizeof(TNPCPosition), &NPCPosition)) return false; - CPythonMiniMap::Instance().RegisterAtlasMark(NPCPosition.bType, NPCPosition.name, NPCPosition.x, NPCPosition.y); + const char* c_szName = nullptr; + if (CPythonNonPlayer::Instance().GetName(NPCPosition.dwVnum, &c_szName)) + { + CPythonMiniMap::Instance().RegisterAtlasMark(NPCPosition.bType, c_szName, NPCPosition.x, NPCPosition.y); + } + else + { + CPythonMiniMap::Instance().RegisterAtlasMark(NPCPosition.bType, NPCPosition.name, NPCPosition.x, NPCPosition.y); + } } return true;