mirror of
https://github.com/minetest/minetest.git
synced 2025-07-01 07:30:23 +02:00
Fix multiple death messages (#5305)
Fix multiple death messages (#3565) and damage server logs after death.
This commit is contained in:
@ -1107,6 +1107,13 @@ void Server::handleCommand_Damage(NetworkPacket* pkt)
|
||||
}
|
||||
|
||||
if (g_settings->getBool("enable_damage")) {
|
||||
if (playerSAO->isDead()) {
|
||||
verbosestream << "Server::ProcessData(): Info: "
|
||||
"Ignoring damage as player " << player->getName()
|
||||
<< " is already dead." << std::endl;
|
||||
return;
|
||||
}
|
||||
|
||||
actionstream << player->getName() << " damaged by "
|
||||
<< (int)damage << " hp at " << PP(playersao->getBasePosition() / BS)
|
||||
<< std::endl;
|
||||
|
Reference in New Issue
Block a user