Fix two interaction obstruction checks (#6793)
This commit is contained in:
@@ -161,12 +161,18 @@ namespace Content.Server.RCD.Systems
|
||||
}
|
||||
|
||||
var coordinates = mapGrid.ToCoordinates(tile.GridIndices);
|
||||
if (coordinates == EntityCoordinates.Invalid ||
|
||||
!_interactionSystem.InRangeUnobstructed(eventArgs.User, coordinates, popup: true))
|
||||
if (coordinates == EntityCoordinates.Invalid)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
var unobstructed = eventArgs.Target == null
|
||||
? _interactionSystem.InRangeUnobstructed(eventArgs.User, coordinates, popup: true)
|
||||
: _interactionSystem.InRangeUnobstructed(eventArgs.User, eventArgs.Target.Value, popup: true);
|
||||
|
||||
if (!unobstructed)
|
||||
return false;
|
||||
|
||||
switch (rcd.Mode)
|
||||
{
|
||||
//Floor mode just needs the tile to be a space tile (subFloor)
|
||||
|
||||
Reference in New Issue
Block a user