Changes required for component tree engine PR (#13109)

This commit is contained in:
Leon Friedrich 2022-12-27 15:34:22 +13:00 committed by GitHub
parent c02fbc3659
commit 7c7c7d3206
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
8 changed files with 5 additions and 15 deletions

View File

@ -29,6 +29,7 @@ public abstract class SharedDoorSystem : EntitySystem
[Dependency] protected readonly SharedAudioSystem Audio = default!;
[Dependency] private readonly EntityLookupSystem _entityLookup = default!;
[Dependency] private readonly SharedAppearanceSystem _appearance = default!;
[Dependency] private readonly OccluderSystem _occluder = default!;
/// <summary>
/// A body must have an intersection percentage larger than this in order to be considered as colliding with a
@ -390,8 +391,8 @@ public abstract class SharedDoorSystem : EntitySystem
if (!collidable)
door.CurrentlyCrushing.Clear();
if (door.Occludes && Resolve(uid, ref occluder, false))
occluder.Enabled = collidable;
if (door.Occludes)
_occluder.SetEnabled(uid, collidable);
}
/// <summary>

View File

@ -186,7 +186,8 @@ namespace Content.Shared.Examine
continue;
}
var bBox = o.BoundingBox.Translated(entMan.GetComponent<TransformComponent>(o.Owner).WorldPosition);
var bBox = o.BoundingBox;
bBox = bBox.Translated(entMan.GetComponent<TransformComponent>(o.Owner).WorldPosition);
if (bBox.Contains(origin.Position) || bBox.Contains(other.Position))
{

View File

@ -127,8 +127,6 @@
mask:
- WallLayer
- type: Occluder
sizeX: 32
sizeY: 32
- type: Transform
anchored: true
- type: Airtight

View File

@ -57,8 +57,6 @@
key: walls
mode: NoSprite
- type: Occluder
sizeX: 32
sizeY: 32
- type: entity
id: MetalDoor

View File

@ -24,8 +24,6 @@
- !type:DoActsBehavior
acts: ["Destruction"]
- type: Occluder
sizeX: 32
sizeY: 32
- type: Airtight
- type: Fixtures
fixtures:

View File

@ -42,8 +42,6 @@
- WallLayer
density: 1000
- type: Occluder
sizeX: 32
sizeY: 32
- type: Airtight
- type: StaticPrice
price: 75

View File

@ -67,8 +67,6 @@
graph: Window
node: tintedWindow
- type: Occluder
sizeX: 32
sizeY: 32
- type: StaticPrice
price: 0.75

View File

@ -62,8 +62,6 @@
- Opaque
- MidImpassable
- type: Occluder
sizeX: 32
sizeY: 32
- type: entity
id: PlasticFlapsAirtightClear