mirror of
https://github.com/EQEmu/Server.git
synced 2026-06-26 11:27:17 +00:00
Remove GetID
This commit is contained in:
@@ -452,19 +452,6 @@ bool LDoNTheme::IsValid(uint32 theme_id)
|
|||||||
return ldon_theme_names.find(theme_id) != ldon_theme_names.end();
|
return ldon_theme_names.find(theme_id) != ldon_theme_names.end();
|
||||||
}
|
}
|
||||||
|
|
||||||
uint8 PetCommand::GetID(std::string pet_command)
|
|
||||||
{
|
|
||||||
auto e = std::find_if(
|
|
||||||
pet_commands.begin(),
|
|
||||||
pet_commands.end(),
|
|
||||||
[&pet_command](const auto &c) {
|
|
||||||
return c.second == pet_command;
|
|
||||||
}
|
|
||||||
);
|
|
||||||
|
|
||||||
return e != pet_commands.end() ? e->first : -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
std::string PetCommand::GetName(uint8 pet_command)
|
std::string PetCommand::GetName(uint8 pet_command)
|
||||||
{
|
{
|
||||||
return IsValid(pet_command) ? pet_commands[pet_command] : "UNKNOWN PET COMMAND";
|
return IsValid(pet_command) ? pet_commands[pet_command] : "UNKNOWN PET COMMAND";
|
||||||
|
|||||||
@@ -880,7 +880,6 @@ namespace PetCommand {
|
|||||||
{ PetCommand::Max, "Max" }
|
{ PetCommand::Max, "Max" }
|
||||||
};
|
};
|
||||||
|
|
||||||
uint8 GetID(std::string pet_command);
|
|
||||||
std::string GetName(uint8 pet_command);
|
std::string GetName(uint8 pet_command);
|
||||||
bool IsValid(uint8 pet_command);
|
bool IsValid(uint8 pet_command);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user