Mercenaries now spawn as the same Gender and Size of the Merchant they are purchased from.

Mercenaries now spawn with randomized facial features when purchased.
Setting a lastname for NPCs will now override any hard coded lastname (such as GM Trainers).
This commit is contained in:
Trevius
2014-12-01 19:54:01 -06:00
parent cbadd8bde1
commit 24ea7a0d45
13 changed files with 549 additions and 540 deletions
+5 -5
View File
@@ -658,10 +658,12 @@ void EntityList::AddNPC(NPC *npc, bool SendSpawnPacket, bool dontqueue)
void EntityList::AddMerc(Merc *merc, bool SendSpawnPacket, bool dontqueue)
{
if (merc) {
if (merc)
{
merc->SetID(GetFreeID());
if (SendSpawnPacket) {
if (SendSpawnPacket)
{
if (dontqueue) {
// Send immediately
EQApplicationPacket *outapp = new EQApplicationPacket();
@@ -673,12 +675,10 @@ void EntityList::AddMerc(Merc *merc, bool SendSpawnPacket, bool dontqueue)
// Queue the packet
NewSpawn_Struct *ns = new NewSpawn_Struct;
memset(ns, 0, sizeof(NewSpawn_Struct));
merc->FillSpawnStruct(ns, merc);
merc->FillSpawnStruct(ns, 0);
AddToSpawnQueue(merc->GetID(), &ns);
safe_delete(ns);
}
//parse->EventMERC(EVENT_SPAWN, merc, nullptr, "", 0);
}
merc_list.insert(std::pair<uint16, Merc *>(merc->GetID(), merc));