Skip to content

Commit

Permalink
Push dead mob check above recursive chunk
Browse files Browse the repository at this point in the history
  • Loading branch information
whatston3 committed Nov 1, 2024
1 parent 5e6405d commit 351c1e7
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions Content.Server/Cargo/Systems/CargoSystem.Shuttle.cs
Original file line number Diff line number Diff line change
Expand Up @@ -323,6 +323,10 @@ private bool CanSell(EntityUid uid, TransformComponent xform)
// Frontier: Look for blacklisted items and stop the selling of the container.
if (_blacklistQuery.HasComponent(uid))
return false;

// Frontier: allow selling dead mobs
if (_mobQuery.TryComp(uid, out var mob) && mob.CurrentState != MobState.Dead)
return false;
// End Frontier

var complete = IsBountyComplete(uid, out var bountyEntities);
Expand All @@ -338,11 +342,6 @@ private bool CanSell(EntityUid uid, TransformComponent xform)
return false;
}

// Frontier: allow selling dead mobs
if (_mobQuery.TryComp(uid, out var mob))
return mob.CurrentState == MobState.Dead;
// End Frontier

return true;
}

Expand Down

0 comments on commit 351c1e7

Please sign in to comment.