mirror of
https://github.com/minetest/minetest.git
synced 2025-09-18 19:30:34 +02:00
Server: Add reason for leave to on_leaveplayer
callbacks
This commit is contained in:
@@ -2683,7 +2683,7 @@ void Server::DeleteClient(u16 peer_id, ClientDeletionReason reason)
|
||||
PlayerSAO *playersao = player->getPlayerSAO();
|
||||
assert(playersao);
|
||||
|
||||
m_script->on_leaveplayer(playersao);
|
||||
m_script->on_leaveplayer(playersao, reason == CDR_TIMEOUT);
|
||||
|
||||
playersao->disconnected();
|
||||
}
|
||||
|
Reference in New Issue
Block a user