mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-15 12:31:31 +00:00
Fixed dynamic merchant list loading. Allows any merchant to be used in any zone.
This commit is contained in:
parent
f81f8ea5d6
commit
b4e4d94061
@ -2,6 +2,7 @@ EQEMu Changelog (Started on Sept 24, 2003 15:50)
|
|||||||
-------------------------------------------------------
|
-------------------------------------------------------
|
||||||
== 11/06/2014 ==
|
== 11/06/2014 ==
|
||||||
demonstar55: Tracking default sort will now be correct order
|
demonstar55: Tracking default sort will now be correct order
|
||||||
|
Trevius: Fixed dynamic merchant list loading. Allows any merchant to be used in any zone.
|
||||||
|
|
||||||
== 11/03/2014 ==
|
== 11/03/2014 ==
|
||||||
Secrets: Fixed an overflow in melee lifetap calculations (int16 vs int32)
|
Secrets: Fixed an overflow in melee lifetap calculations (int16 vs int32)
|
||||||
|
|||||||
@ -445,7 +445,7 @@ void Zone::LoadNewMerchantData(uint32 merchantid) {
|
|||||||
|
|
||||||
std::list<MerchantList> merlist;
|
std::list<MerchantList> merlist;
|
||||||
std::string query = StringFormat("SELECT item, slot, faction_required, level_required, alt_currency_cost, "
|
std::string query = StringFormat("SELECT item, slot, faction_required, level_required, alt_currency_cost, "
|
||||||
"classes_required FROM merchantlist WHERE merchantid=%d ORDER BY slot", merchantid);
|
"classes_required, probability FROM merchantlist WHERE merchantid=%d ORDER BY slot", merchantid);
|
||||||
auto results = database.QueryDatabase(query);
|
auto results = database.QueryDatabase(query);
|
||||||
if (!results.Success()) {
|
if (!results.Success()) {
|
||||||
LogFile->write(EQEMuLog::Error, "Error in LoadNewMerchantData query '%s' %s", query.c_str(), results.ErrorMessage().c_str());
|
LogFile->write(EQEMuLog::Error, "Error in LoadNewMerchantData query '%s' %s", query.c_str(), results.ErrorMessage().c_str());
|
||||||
@ -459,8 +459,9 @@ void Zone::LoadNewMerchantData(uint32 merchantid) {
|
|||||||
ml.slot = atoul(row[1]);
|
ml.slot = atoul(row[1]);
|
||||||
ml.faction_required = atoul(row[2]);
|
ml.faction_required = atoul(row[2]);
|
||||||
ml.level_required = atoul(row[3]);
|
ml.level_required = atoul(row[3]);
|
||||||
ml.alt_currency_cost = atoul(row[3]);
|
ml.alt_currency_cost = atoul(row[4]);
|
||||||
ml.classes_required = atoul(row[4]);
|
ml.classes_required = atoul(row[5]);
|
||||||
|
ml.probability = atoul(row[6]);
|
||||||
merlist.push_back(ml);
|
merlist.push_back(ml);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user