mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-14 15:41:30 +00:00
[Commands] Cleanup #viewzoneloot Command. (#1702)
- Cleanup message logic.
This commit is contained in:
parent
605b3d3a27
commit
a64e326c68
@ -15898,10 +15898,12 @@ void command_viewzoneloot(Client *c, const Seperator *sep)
|
|||||||
);
|
);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (auto npc_entity : npc_list) {
|
for (auto npc_entity : npc_list) {
|
||||||
auto current_npc_item_list = npc_entity.second->GetItemList();
|
auto current_npc_item_list = npc_entity.second->GetItemList();
|
||||||
zone_loot_list.insert({ npc_entity.second->GetID(), current_npc_item_list });
|
zone_loot_list.insert({ npc_entity.second->GetID(), current_npc_item_list });
|
||||||
}
|
}
|
||||||
|
|
||||||
for (auto loot_item : zone_loot_list) {
|
for (auto loot_item : zone_loot_list) {
|
||||||
uint32 current_entity_id = loot_item.first;
|
uint32 current_entity_id = loot_item.first;
|
||||||
auto current_item_list = loot_item.second;
|
auto current_item_list = loot_item.second;
|
||||||
@ -15963,6 +15965,7 @@ void command_viewzoneloot(Client *c, const Seperator *sep)
|
|||||||
) :
|
) :
|
||||||
"not dropping"
|
"not dropping"
|
||||||
);
|
);
|
||||||
|
|
||||||
c->Message(
|
c->Message(
|
||||||
Chat::White,
|
Chat::White,
|
||||||
fmt::format(
|
fmt::format(
|
||||||
@ -15976,13 +15979,13 @@ void command_viewzoneloot(Client *c, const Seperator *sep)
|
|||||||
std::string drop_string = (
|
std::string drop_string = (
|
||||||
loot_amount > 0 ?
|
loot_amount > 0 ?
|
||||||
fmt::format(
|
fmt::format(
|
||||||
"{} {} {}",
|
"{} {} dropping",
|
||||||
(loot_amount > 1 ? "items" : "item"),
|
(loot_amount > 1 ? "items" : "item"),
|
||||||
(loot_amount > 1 ? "are" : "is"),
|
(loot_amount > 1 ? "are" : "is")
|
||||||
(loot_amount > 1 ? "dropping" : "not dropping")
|
|
||||||
) :
|
) :
|
||||||
"items are dropping"
|
"items are dropping"
|
||||||
);
|
);
|
||||||
|
|
||||||
c->Message(
|
c->Message(
|
||||||
Chat::White,
|
Chat::White,
|
||||||
fmt::format(
|
fmt::format(
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user