Fix handheld instruments not working
This commit is contained in:
@@ -307,7 +307,9 @@ namespace Content.Server.Instruments
|
|||||||
{
|
{
|
||||||
if (!user.TryGetComponent(out ActorComponent? actor)) return;
|
if (!user.TryGetComponent(out ActorComponent? actor)) return;
|
||||||
|
|
||||||
if (InstrumentPlayer != null || !EntitySystem.Get<ActionBlockerSystem>().CanInteract(user)) return;
|
if ((!Handheld && InstrumentPlayer != null)
|
||||||
|
|| (Handheld && actor.PlayerSession != InstrumentPlayer)
|
||||||
|
|| !EntitySystem.Get<ActionBlockerSystem>().CanInteract(user)) return;
|
||||||
|
|
||||||
InstrumentPlayer = actor.PlayerSession;
|
InstrumentPlayer = actor.PlayerSession;
|
||||||
OpenUserInterface(InstrumentPlayer);
|
OpenUserInterface(InstrumentPlayer);
|
||||||
|
|||||||
4
Resources/Changelog/Parts/instrument.yml
Normal file
4
Resources/Changelog/Parts/instrument.yml
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
author: Zumorica
|
||||||
|
changes:
|
||||||
|
- type: Fix # One of the following: Add, Remove, Tweak, Fix
|
||||||
|
message: Fixes handheld instruments not working.
|
||||||
Reference in New Issue
Block a user