Fix: Don't deploy foldables when clicking on items inside containers (#38709)
* Fix * Apply suggestions from code review --------- Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>
This commit is contained in:
@@ -59,6 +59,10 @@ public sealed class DeployFoldableSystem : EntitySystem
|
|||||||
if (args.Handled || !args.CanReach)
|
if (args.Handled || !args.CanReach)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
// Don't do anything unless you clicked on the floor.
|
||||||
|
if (args.Target.HasValue)
|
||||||
|
return;
|
||||||
|
|
||||||
if (!TryComp<FoldableComponent>(ent, out var foldable))
|
if (!TryComp<FoldableComponent>(ent, out var foldable))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user