Fix dead people standing up after being stunned (#3330)
* fix crit/dead players standing up * actually fix crit/dead players standing up * nullable + missed check Co-authored-by: cyclowns <cyclowns@protonmail.ch>
This commit is contained in:
@@ -353,13 +353,16 @@ namespace Content.Server.GameObjects.Components.Instruments
|
||||
|
||||
UserInterface?.CloseAll();
|
||||
|
||||
if(Handheld)
|
||||
EntitySystem.Get<StandingStateSystem>().DropAllItemsInHands(mob, false);
|
||||
|
||||
if (mob != null && mob.TryGetComponent(out StunnableComponent? stun))
|
||||
if (mob != null)
|
||||
{
|
||||
stun.Stun(1);
|
||||
Clean();
|
||||
if (Handheld)
|
||||
EntitySystem.Get<StandingStateSystem>().DropAllItemsInHands(mob, false);
|
||||
|
||||
if (mob.TryGetComponent(out StunnableComponent? stun))
|
||||
{
|
||||
stun.Stun(1);
|
||||
Clean();
|
||||
}
|
||||
}
|
||||
|
||||
InstrumentPlayer = null;
|
||||
|
||||
Reference in New Issue
Block a user