mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-30 15:01:29 +00:00
Eye of Zomm needed support in OP_ClientUpdate.
This commit is contained in:
parent
7eb2e834b1
commit
ff59255e63
@ -4384,7 +4384,21 @@ void Client::Handle_OP_ClientUpdate(const EQApplicationPacket *app) {
|
||||
/* Update the boat's position on the server, without sending an update */
|
||||
boat->GMMove(ppu->x_pos, ppu->y_pos, ppu->z_pos, EQ12toFloat(ppu->heading), false);
|
||||
return;
|
||||
} else return;
|
||||
}
|
||||
else {
|
||||
// Eye of Zomm needs code here to track position of the eye on server
|
||||
// so that other clients see it. I could add a check here for eye of zomm
|
||||
// race, to limit this code, but this should handle any client controlled
|
||||
// mob that gets updates from OP_ClientUpdate
|
||||
Mob *cmob = entity_list.GetMob(ppu->spawn_id);
|
||||
if (cmob != nullptr) {
|
||||
cmob->SetPosition(ppu->x_pos, ppu->y_pos, ppu->z_pos);
|
||||
cmob->SetHeading(EQ12toFloat(ppu->heading));
|
||||
mMovementManager->SendCommandToClients(cmob, 0.0, 0.0, 0.0, 0.0, 0, ClientRangeAny, nullptr, this);
|
||||
cmob->CastToNPC()->SaveGuardSpot(glm::vec4(ppu->x_pos, ppu->y_pos, ppu->z_pos, EQ12toFloat(ppu->heading)));
|
||||
}
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
if (IsDraggingCorpse())
|
||||
|
||||
@ -727,7 +727,8 @@ void MobMovementManager::SendCommandToClients(
|
||||
float delta_heading,
|
||||
int anim,
|
||||
ClientRange range,
|
||||
Client* single_client
|
||||
Client* single_client,
|
||||
Client* ignore_client
|
||||
)
|
||||
{
|
||||
if (range == ClientRangeNone) {
|
||||
@ -745,6 +746,10 @@ void MobMovementManager::SendCommandToClients(
|
||||
continue;
|
||||
}
|
||||
|
||||
if (ignore_client && c == ignore_client) {
|
||||
continue;
|
||||
}
|
||||
|
||||
_impl->Stats.TotalSent++;
|
||||
|
||||
if (anim != 0) {
|
||||
@ -769,6 +774,10 @@ void MobMovementManager::SendCommandToClients(
|
||||
continue;
|
||||
}
|
||||
|
||||
if (ignore_client && c == ignore_client) {
|
||||
continue;
|
||||
}
|
||||
|
||||
float distance = c->CalculateDistance(mob->GetX(), mob->GetY(), mob->GetZ());
|
||||
|
||||
bool match = false;
|
||||
|
||||
@ -59,7 +59,8 @@ public:
|
||||
float delta_heading,
|
||||
int anim,
|
||||
ClientRange range,
|
||||
Client* single_client = nullptr
|
||||
Client* single_client = nullptr,
|
||||
Client* ignore_client = nullptr
|
||||
);
|
||||
|
||||
float FixHeading(float in);
|
||||
|
||||
@ -1561,7 +1561,7 @@ bool Mob::SpellEffect(Mob* caster, uint16 spell_id, float partial, int level_ove
|
||||
char eye_name[64];
|
||||
snprintf(eye_name, sizeof(eye_name), "Eye_of_%s", caster->GetCleanName());
|
||||
int duration = CalcBuffDuration(caster, this, spell_id) * 6;
|
||||
caster->TemporaryPets(spell_id, nullptr, eye_name, duration);
|
||||
caster->TemporaryPets(spell_id, nullptr, eye_name, duration, false);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user