mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-12 09:31:30 +00:00
* Expansion version routing * CheckForImproperContentFiles rule * Update world_content_service.cpp * Update client.cpp * Update client.cpp * Update CheckForImproperContentFiles * Remove nek pok check * Remove file checking * Remove * Command and dev tools menu tweaks * Update world_content_service.cpp * Update world_content_service.cpp * Update version path * Update content_filter_criteria.h * Update content_filter_criteria.h * Update quest_parser_collection.cpp * Update comments * PR feedback * Update client_packet.cpp * Remove notes column for display cleanliness
31 lines
851 B
C++
31 lines
851 B
C++
#include "../../client.h"
|
|
#include "../../dialogue_window.h"
|
|
|
|
void ShowContentFlags(Client *c, const Seperator *sep)
|
|
{
|
|
Client *t = c;
|
|
if (c->GetTarget() && c->GetTarget()->IsClient()) {
|
|
t = c->GetTarget()->CastToClient();
|
|
}
|
|
|
|
std::string flags = DialogueWindow::TableRow(
|
|
DialogueWindow::TableCell("id") +
|
|
DialogueWindow::TableCell("flag_name") +
|
|
DialogueWindow::TableCell("enabled")
|
|
);
|
|
|
|
for (auto &f: ContentFlagsRepository::All(database)) {
|
|
flags += DialogueWindow::TableRow(
|
|
DialogueWindow::TableCell(std::to_string(f.id)) +
|
|
DialogueWindow::TableCell(f.flag_name) +
|
|
DialogueWindow::TableCell(
|
|
f.enabled ?
|
|
DialogueWindow::ColorMessage("forest_green", "yes") :
|
|
DialogueWindow::ColorMessage("red", "no")
|
|
)
|
|
);
|
|
}
|
|
|
|
c->SendPopupToClient("Server Content Flag Settings", DialogueWindow::Table(flags).c_str());
|
|
}
|