From 4935052857fd0c73b0ae415dfbdcdfa685b667e7 Mon Sep 17 00:00:00 2001 From: xshxdex98 Date: Wed, 7 Oct 2026 14:53:11 -0500 Subject: [PATCH] Leave the host's falling bipeds to the host on a client A client ran biped_falling_damage's outside-the-world erase on the host's AI bipeds too: object_delete refuses them there (network_objects_may_delete), so nothing was erased, but each was logged as erased. On a co-op client of a crowded game that was hundreds of false warnings. The host erases them, and its delete reaches the clients. --- source/units/bipeds.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/source/units/bipeds.c b/source/units/bipeds.c index 876603e0..b6476acb 100644 --- a/source/units/bipeds.c +++ b/source/units/bipeds.c @@ -277,6 +277,10 @@ symbols in this file: #include "structures/structure_bsp_definitions.h" #include "network_coop.h" /* port: port/linux/game/network_coop.c */ +/* port: port/linux/game/network_objects.c's (a client deletes the host's +objects on the host's word alone) */ +boolean network_objects_may_delete(long object_index); + /* port: an unarmed player's melee's length, in ticks (a weapon's is about this: its first person melee animation, sped up a quarter) */ #define UNARMED_MELEE_TICKS 16 @@ -830,9 +834,12 @@ static void biped_falling_damage( object_cause_damage(&damage, biped_index, NONE, NONE, NONE, NULL); } + /* (port: not the host's biped on a client, which the host erases: + the delete was refused, and logged as done) */ if (!game_engine_running() && TEST_FLAG(biped->object.flags, _object_outside_of_map_bit) && - player_index_from_unit_index(biped_index) == NONE) + player_index_from_unit_index(biped_index) == NONE && + network_objects_may_delete(biped_index)) { long actor_index = biped->unit.swarm_actor_index;