From 294ad987763014c5d20d4260b76fee831581c87a Mon Sep 17 00:00:00 2001 From: chmodsayshello Date: Sat, 2 Sep 2023 22:58:11 +0200 Subject: [PATCH] Send ever lasting particle spawners to all players (#13774) --- src/server.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/server.cpp b/src/server.cpp index 445955020..3e11709eb 100644 --- a/src/server.cpp +++ b/src/server.cpp @@ -1621,8 +1621,9 @@ void Server::SendAddParticleSpawner(session_t peer_id, u16 protocol_version, ) / 4.0f * BS; const float radius_sq = radius * radius; /* Don't send short-lived spawners to distant players. - * This could be replaced with proper tracking at some point. */ - const bool distance_check = !attached_id && p.time <= 1.0f; + * This could be replaced with proper tracking at some point. + * A lifetime of 0 means that the spawner exists forever.*/ + const bool distance_check = !attached_id && p.time <= 1.0f && p.time != 0.0f; for (const session_t client_id : clients) { RemotePlayer *player = m_env->getPlayer(client_id);