mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2025-11-02 05:32:07 +00:00
Slash commands: Update compares (#1270)
use case insensitive compare use character name for kill instead of account name Use correct Id for muting when a player is found
This commit is contained in:
@@ -228,9 +228,9 @@ Player* Player::GetPlayer(const std::string& name) {
|
||||
|
||||
for (auto* character : characters) {
|
||||
if (!character->IsPlayer()) continue;
|
||||
|
||||
if (character->GetCharacter()->GetName() == name) {
|
||||
return static_cast<Player*>(character);
|
||||
|
||||
if (GeneralUtils::CaseInsensitiveStringCompare(name, character->GetCharacter()->GetName())) {
|
||||
return dynamic_cast<Player*>(character);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user