It doesn't remove the spawn. The spawn continues.
See that: else if (p->m_table.bType == CHAR_TYPE_NPC || p->m_table.bType == CHAR_TYPE_WARP || p->m_table.bType == CHAR_TYPE_GOTO) doesn't include CHAR_TYPE_MONSTER and monsters are spawned.
-------------------------------------
What it does?
Basically we don't add the position of npc with vnum 9004 to m_mapNPCPosition[lMapIndex] (it isn't related with the spawn), so when the game send the packet of npc's positions in each map, it will not contain the position of npc with vnum 9004 and it isn't marked in atlas.
You can prove this by seeing the next functions:
InsertNPCPosition in sectree_manager.cpp:
void SECTREE_MANAGER::InsertNPCPosition(long lMapIndex, BYTE bType, const char* szName, long x, long y)
{
m_mapNPCPosition[lMapIndex].push_back(npc_info(bType, szName, x, y));
}
And SendNPCPosition in the same file:
void SECTREE_MANAGER::SendNPCPosition(LPCHARACTER ch)
{
LPDESC d = ch->GetDesc();
if (!d)
return;
long lMapIndex = ch->GetMapIndex();
if (m_mapNPCPosition[lMapIndex].empty())
return;
TEMP_BUFFER buf;
TPacketGCNPCPosition p;
p.header = HEADER_GC_NPC_POSITION;
p.count = m_mapNPCPosition[lMapIndex].size();
TNPCPosition np;
// TODO m_mapNPCPosition[lMapIndex] 를 보내주세요
itertype(m_mapNPCPosition[lMapIndex]) it;
for (it = m_mapNPCPosition[lMapIndex].begin(); it != m_mapNPCPosition[lMapIndex].end(); ++it)
{
np.bType = it->bType;
strlcpy(np.name, it->name, sizeof(np.name));
np.x = it->x;
np.y = it->y;
buf.write(&np, sizeof(np));
}
p.size = sizeof(p) + buf.size();
if (buf.size())
{
d->BufferedPacket(&p, sizeof(TPacketGCNPCPosition));
d->Packet(buf.read_peek(), buf.size());
}
else
d->Packet(&p, sizeof(TPacketGCNPCPosition));
}
Then go to client -> ../UserInterface/PythonNetworkStreamPhaseGame.cpp and see CPythonNetworkStream::RecvNPCList()
bool CPythonNetworkStream::RecvNPCList()
{
TPacketGCNPCPosition kNPCPosition;
if (!Recv(sizeof(kNPCPosition), &kNPCPosition))
return false;
assert(int(kNPCPosition.size)-sizeof(kNPCPosition) == kNPCPosition.count*sizeof(TNPCPosition) && "HEADER_GC_NPC_POSITION");
CPythonMiniMap::Instance().ClearAtlasMarkInfo();
for (int i = 0; i < kNPCPosition.count; ++i)
{
TNPCPosition NPCPosition;
if (!Recv(sizeof(TNPCPosition), &NPCPosition))
return false;
CPythonMiniMap::Instance().RegisterAtlasMark(NPCPosition.bType, NPCPosition.name, NPCPosition.x, NPCPosition.y);
}
return true;
}
If you can see at the start we get the packet of npc position and in the last lines we mark the position in the atlas: CPythonMiniMap::Instance().RegisterAtlasMark(NPCPosition.bType, NPCPosition.name, NPCPosition.x, NPCPosition.y);