server
server copied to clipboard
🐛 Arasy/Eminent sachet blocks exp/limit point gain with pet out onMobDeath--other jobs may be impacted too
- [x] I have paid attention to this example and will edit again if need be to not break the formatting, or I will be ignored
- [x] I have searched existing issues to see if the issue has already been opened, and I have checked the commit log to see if the issue has been resolved since my server was last updated
- [x] I have read and understood the Contributing Guide
Branch affected by issue
base
, discovered on xiweb
Steps to reproduce
On SMN, kill appropriate level targets for xp/lp gain with either Eminent or Arasy Sachet equipped while the SMN has a pet summoned onmobDeath, and neither exp or limit points are earned.
Would note that CP is not impacted--If the target is appropriate to grant CP, that is still earned, just not xp/lp.
Release pet, kill same targets and exp/limit points can be earned if pet is not summoned onmobdeath.
This does not occur if something else like mana ampule is equipped in the same slot without changing any other gear or conditions.
This should likely be tested against other pet ilevel boosting gear in a similar fashion (ie, for PUP).
Expected behavior
SMN should be able to gain xp/lp on level appropriate targets while either Eminent or Arasy Sachet is equipped and that SMN's pet is still summoned onmobdeath. Same should hold true as well for other similar pet ilevel boosting items on other jobs as well.
Also noticed same issue onMobDeath on DRG if having Dragoon's Collar equipped with wyvern out.
Bug is probably here:
void CEnmityContainer::UpdateEnmityFromDamage(CBattleEntity* PEntity, int32 Damage)
{
TracyZoneScoped;
Damage = (Damage < 1 ? 1 : Damage);
int16 damageMod = battleutils::GetEnmityModDamage(m_EnmityHolder->GetMLevel());
int32 CE = (int32)(80.f / damageMod * Damage);
int32 VE = (int32)(240.f / damageMod * Damage);
UpdateEnmity(PEntity, CE, VE);
if (m_EnmityHolder && m_EnmityHolder->m_HiPCLvl < PEntity->GetMLevel())
{
m_EnmityHolder->m_HiPCLvl = PEntity->GetMLevel();
}
}
I assume the pet gains ilvl as "real" level, so the mob tacks on lvl 119+ as m_HiPCLvl
dirtyExp uses some similar logic to this and this could potentially fix it:
void CEnmityContainer::UpdateEnmityFromDamage(CBattleEntity* PEntity, int32 Damage)
{
TracyZoneScoped;
if (m_EnmityHolder)
{
Damage = (Damage < 1 ? 1 : Damage);
int16 damageMod = battleutils::GetEnmityModDamage(m_EnmityHolder->GetMLevel());
int32 CE = (int32)(80.f / damageMod * Damage);
int32 VE = (int32)(240.f / damageMod * Damage);
UpdateEnmity(PEntity, CE, VE);
if (PEntity->objtype != TYPE_PC)
{
if (PEntity->PMaster && PEntity->PMaster->objtype == TYPE_PC)
{
m_EnmityHolder->m_HiPCLvl = PEntity->PMaster->GetMLevel();
return;
}
}
m_EnmityHolder->m_HiPCLvl = PEntity->GetMLevel();
}
}
Alternatively, we could clamp m_HiPCLvl
to max at 99 when distributing exp etc. I don't know which approach would be better, but certainly AFAIK "real" pet levels are equal to yours for the purposes of exp. Should be testable with using ilvl sachet or dragoon's collar on retail and using no other ilvl gear.