Remove obsolete Fixture.Body references (#16259)

This commit is contained in:
Leon Friedrich
2023-05-09 19:21:26 +12:00
committed by GitHub
parent dac7025cc5
commit 2bd5fb3736
32 changed files with 67 additions and 77 deletions

View File

@@ -60,7 +60,7 @@ public sealed class ContainmentFieldGeneratorSystem : EntitySystem
/// </summary>
private void HandleGeneratorCollide(EntityUid uid, ContainmentFieldGeneratorComponent component, ref StartCollideEvent args)
{
if (_tags.HasTag(args.OtherFixture.Body.Owner, component.IDTag))
if (_tags.HasTag(args.OtherEntity, component.IDTag))
{
ReceivePower(component.PowerReceived, component);
component.Accumulator = 0f;

View File

@@ -24,7 +24,7 @@ public sealed class ContainmentFieldSystem : EntitySystem
private void HandleFieldCollide(EntityUid uid, ContainmentFieldComponent component, ref StartCollideEvent args)
{
var otherBody = args.OtherFixture.Body.Owner;
var otherBody = args.OtherEntity;
if (TryComp<SpaceGarbageComponent>(otherBody, out var garbage))
{

View File

@@ -421,7 +421,7 @@ public sealed class EventHorizonSystem : SharedEventHorizonSystem
if (args.OurFixture.ID != comp.HorizonFixtureId)
return;
AttemptConsumeEntity(args.OtherFixture.Body.Owner, comp);
AttemptConsumeEntity(args.OtherEntity, comp);
}
/// <summary>

View File

@@ -123,7 +123,7 @@ public sealed class SingularityGeneratorSystem : EntitySystem
/// <param name="args">The state of the beginning of the collision.</param>
private void HandleParticleCollide(EntityUid uid, ParticleProjectileComponent component, ref StartCollideEvent args)
{
if (EntityManager.TryGetComponent<SingularityGeneratorComponent?>(args.OtherFixture.Body.Owner, out var singularityGeneratorComponent))
if (EntityManager.TryGetComponent<SingularityGeneratorComponent?>(args.OtherEntity, out var singularityGeneratorComponent))
{
SetPower(
singularityGeneratorComponent,