fix(DB/Creatures): Nat Pagle should display vendor icon if player completed Nat's Measuring Tap quest. (#10657)

Moved c++ script to DB. Original author: @offl
Fixes #10559
This commit is contained in:
UltraNix
2022-02-17 01:13:39 +01:00
committed by GitHub
parent faf88c7f9c
commit 1366838a05
7 changed files with 68 additions and 49 deletions

View File

@@ -20099,6 +20099,11 @@ void Unit::BuildValuesUpdate(uint8 updateType, ByteBuffer* data, Player* target)
appendValue &= ~UNIT_NPC_FLAG_SPELLCLICK;
}
if (!target->CanSeeVendor(creature))
{
appendValue &= ~UNIT_NPC_FLAG_VENDOR_MASK;
}
if (!creature->IsValidTrainerForPlayer(target, &appendValue))
{
appendValue &= ~UNIT_NPC_FLAG_TRAINER;