mirror of
https://github.com/mangosfour/server.git
synced 2025-12-13 04:37:00 +00:00
[12136] Fix typos
Signed-off-by: Yaki Khadafi <elsoldollo@gmail.com>
This commit is contained in:
parent
05b6f3072b
commit
faec714783
7 changed files with 24 additions and 24 deletions
|
|
@ -810,20 +810,20 @@ struct CreatureTypeEntry
|
|||
struct CurrencyTypesEntry
|
||||
{
|
||||
uint32 ID; // 0
|
||||
//uint32 Category; // 1
|
||||
//uint32 Category; // 1
|
||||
DBCString name; // 2
|
||||
//char* iconName; // 3
|
||||
//uint32 unk4; // 4
|
||||
//uint32 unk5; // 5
|
||||
//uint32 unk6; // 6
|
||||
uint32 TotalCount; // 7
|
||||
uint32 WeekCount; // 8
|
||||
//char* iconName; // 3
|
||||
//char* iconName2; // 4
|
||||
//uint32 unk5; // 5
|
||||
//uint32 unk6; // 6
|
||||
uint32 TotalCap; // 7
|
||||
uint32 WeekCap; // 8
|
||||
uint32 Flags; // 9
|
||||
//DBCString description; // 10
|
||||
//DBCString description; // 10
|
||||
|
||||
bool HasPrecision() const { return Flags & CURRENCY_FLAG_HAS_PRECISION; }
|
||||
bool HasPrecision() const { return Flags & CURRENCY_FLAG_HAS_PRECISION; }
|
||||
bool HasSeasonCount() const { return Flags & CURRENCY_FLAG_HAS_SEASON_COUNT; }
|
||||
float GetPrecision() const { return HasPrecision() ? CURRENCY_PRECISION : 1.0f; }
|
||||
float GetPrecision() const { return HasPrecision() ? CURRENCY_PRECISION : 1.0f; }
|
||||
};
|
||||
|
||||
struct DungeonEncounterEntry
|
||||
|
|
|
|||
|
|
@ -530,7 +530,7 @@ void WorldSession::HandleBuyItemOpcode(WorldPacket& recv_data)
|
|||
}
|
||||
case VENDOR_ITEM_TYPE_CURRENCY:
|
||||
{
|
||||
GetPlayer()->BuyCurrencyFromVendorSlot(vendorGuid, slot, item, count);
|
||||
GetPlayer()->BuyCurrencyFromVendorSlot(vendorGuid, slot, item, 1);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -4283,11 +4283,11 @@ void ObjectMgr::LoadQuests()
|
|||
qinfo->GetQuestId(), j + 1, qinfo->ReqCurrencyId[j], j + 1, qinfo->ReqCurrencyCount[j]);
|
||||
qinfo->ReqCurrencyId[j] = 0;
|
||||
}
|
||||
else if (currencyEntry->TotalCount && uint32(qinfo->ReqCurrencyCount[j] * currencyEntry->GetPrecision()) > currencyEntry->TotalCount)
|
||||
else if (currencyEntry->TotalCap && qinfo->ReqCurrencyCount[j] > currencyEntry->TotalCap)
|
||||
{
|
||||
sLog.outErrorDb("Quest %u has `ReqCurrencyCount%d` = %u but currency %u has max count %u / %u (precision).",
|
||||
qinfo->GetQuestId(), j + 1, qinfo->ReqCurrencyCount[j], qinfo->ReqCurrencyId[j], currencyEntry->TotalCount, uint32(currencyEntry->GetPrecision()));
|
||||
qinfo->ReqCurrencyCount[j] = currencyEntry->TotalCount;
|
||||
sLog.outErrorDb("Quest %u has `ReqCurrencyCount%d` = %u but currency %u has max count %u.",
|
||||
qinfo->GetQuestId(), j + 1, qinfo->ReqCurrencyCount[j], qinfo->ReqCurrencyId[j], currencyEntry->TotalCap);
|
||||
qinfo->ReqCurrencyCount[j] = currencyEntry->TotalCap;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -19675,12 +19675,11 @@ bool Player::BuyCurrencyFromVendorSlot(ObjectGuid vendorGuid, uint32 vendorslot,
|
|||
if (crItem->item != currencyId) // store diff item (cheating)
|
||||
return false;
|
||||
|
||||
if (crItem->maxcount != count)
|
||||
if (!crItem->maxcount)
|
||||
{
|
||||
DEBUG_LOG("WORLD: BuyCurrencyFromVendorSlot - %s: count (%u) != crItem->maxcount (%u) for currency %u and player %s.",
|
||||
vendorGuid.GetString().c_str(), count, crItem->maxcount, currencyId, GetGuidStr().c_str());
|
||||
|
||||
count = crItem->maxcount;
|
||||
DEBUG_LOG("WORLD: BuyCurrencyFromVendorSlot - %s: crItem->maxcount (%u) == 0 for currency %u and player %s.",
|
||||
vendorGuid.GetString().c_str(), crItem->maxcount, currencyId, GetGuidStr().c_str());
|
||||
return false;
|
||||
}
|
||||
|
||||
if (uint32 extendedCostId = crItem->ExtendedCost)
|
||||
|
|
|
|||
|
|
@ -195,9 +195,9 @@ Quest::Quest(Field* questRecord)
|
|||
++m_rewchoiceitemscount;
|
||||
}
|
||||
|
||||
for (int i = 0; i < QUEST_REWARD_CURRENCY_COUNT; ++i)
|
||||
for (int i = 0; i < QUEST_REQUIRED_CURRENCY_COUNT; ++i)
|
||||
{
|
||||
if (RewCurrencyId[i])
|
||||
if (ReqCurrencyId[i])
|
||||
++m_reqCurrencyCount;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -219,7 +219,8 @@ enum ItemQualities
|
|||
ITEM_QUALITY_EPIC = 4, // PURPLE
|
||||
ITEM_QUALITY_LEGENDARY = 5, // ORANGE
|
||||
ITEM_QUALITY_ARTIFACT = 6, // LIGHT YELLOW
|
||||
ITEM_QUALITY_HEIRLOOM = 7
|
||||
ITEM_QUALITY_HEIRLOOM = 7,
|
||||
ITEM_QUALITY_UNKNOWN = 10,
|
||||
};
|
||||
|
||||
#define MAX_ITEM_QUALITY 8
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
#ifndef __REVISION_NR_H__
|
||||
#define __REVISION_NR_H__
|
||||
#define REVISION_NR "12135"
|
||||
#define REVISION_NR "12136"
|
||||
#endif // __REVISION_NR_H__
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue