mirror of
https://github.com/EQEmu/Server.git
synced 2026-04-10 16:12:25 +00:00
Filter forage [skip ci]
This commit is contained in:
parent
dadd674b63
commit
68a2af1bce
@ -55,9 +55,25 @@ uint32 ZoneDatabase::GetZoneForage(uint32 ZoneID, uint8 skill) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
uint32 chancepool = 0;
|
uint32 chancepool = 0;
|
||||||
std::string query = StringFormat("SELECT itemid, chance FROM "
|
std::string query = fmt::format(
|
||||||
"forage WHERE zoneid = '%i' and level <= '%i' "
|
SQL(
|
||||||
"LIMIT %i", ZoneID, skill, FORAGE_ITEM_LIMIT);
|
SELECT
|
||||||
|
itemid,
|
||||||
|
chance
|
||||||
|
FROM
|
||||||
|
forage
|
||||||
|
WHERE
|
||||||
|
zoneid = '{}'
|
||||||
|
and level <= '{}'
|
||||||
|
{}
|
||||||
|
LIMIT
|
||||||
|
{}
|
||||||
|
),
|
||||||
|
ZoneID,
|
||||||
|
skill,
|
||||||
|
ContentFilterCriteria::apply(),
|
||||||
|
FORAGE_ITEM_LIMIT
|
||||||
|
);
|
||||||
auto results = QueryDatabase(query);
|
auto results = QueryDatabase(query);
|
||||||
if (!results.Success()) {
|
if (!results.Success()) {
|
||||||
return 0;
|
return 0;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user