From 5f6e9e98964234331c44f696b8dc69b2c222e706 Mon Sep 17 00:00:00 2001 From: Lacyway <20912169+Lacyway@users.noreply.github.com> Date: Mon, 16 Dec 2024 19:55:34 +0100 Subject: [PATCH] Add server check on corpses --- Fika.Core/Coop/Players/CoopPlayer.cs | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/Fika.Core/Coop/Players/CoopPlayer.cs b/Fika.Core/Coop/Players/CoopPlayer.cs index f7af8c31..e6c2c84c 100644 --- a/Fika.Core/Coop/Players/CoopPlayer.cs +++ b/Fika.Core/Coop/Players/CoopPlayer.cs @@ -629,9 +629,14 @@ public override void OnPhraseTold(EPhraseTrigger @event, TaggedClip clip, TagBan public override Corpse CreateCorpse() { - Corpse corpse = base.CreateCorpse(); - CorpsePositionSyncer.Create(corpse.gameObject, corpse); - return corpse; + if (FikaBackendUtils.IsServer) + { + Corpse corpse = base.CreateCorpse(); + CorpsePositionSyncer.Create(corpse.gameObject, corpse); + return corpse; + } + + return CreateCorpse(Velocity); } public override void OperateStationaryWeapon(StationaryWeapon stationaryWeapon, GStruct177.EStationaryCommand command)