Fix the ability to kill clumsy mobs by force climbing (#33844)

* Make clumsy work only when dragged by owner entity & Check for reclaimer comp

* Revert "Make clumsy work only when dragged by owner entity & Check for reclaimer comp"

This reverts commit 7ff984bbc2e53f7070580a4cc4b1b43f8f0461d0.

* Remove check that passes if somebody forces us to climb
This commit is contained in:
MilenVolf
2025-04-15 01:04:56 +03:00
committed by GitHub
parent 05ee55fa3e
commit fc12739df0

View File

@@ -38,7 +38,7 @@ public sealed class ClumsySystem : EntitySystem
private void BeforeHyposprayEvent(Entity<ClumsyComponent> ent, ref SelfBeforeHyposprayInjectsEvent args)
{
// Clumsy people sometimes inject themselves! Apparently syringes are clumsy proof...
// checks if ClumsyHypo is false, if so, skips.
if (!ent.Comp.ClumsyHypo)
return;
@@ -54,7 +54,7 @@ public sealed class ClumsySystem : EntitySystem
private void BeforeDefibrillatorZapsEvent(Entity<ClumsyComponent> ent, ref SelfBeforeDefibrillatorZapsEvent args)
{
// Clumsy people sometimes defib themselves!
// checks if ClumsyDefib is false, if so, skips.
if (!ent.Comp.ClumsyDefib)
return;
@@ -103,8 +103,7 @@ public sealed class ClumsySystem : EntitySystem
// This event is called in shared, thats why it has all the extra prediction stuff.
var rand = new System.Random((int)_timing.CurTick.Value);
// If someone is putting you on the table, always get past the guard.
if (!_cfg.GetCVar(CCVars.GameTableBonk) && args.PuttingOnTable == ent.Owner && !rand.Prob(ent.Comp.ClumsyDefaultCheck))
if (!_cfg.GetCVar(CCVars.GameTableBonk) && !rand.Prob(ent.Comp.ClumsyDefaultCheck))
return;
HitHeadClumsy(ent, args.BeingClimbedOn);