* Revert "Fix chat bubbles (#25643)" This reverts commit23d2c4d924. * Revert "Fixes obsolete Transform warnings in Content. (#25256)" This reverts commitf284b43ff6.
This commit is contained in:
@@ -7,7 +7,6 @@ namespace Content.Server.Xenoarchaeology.XenoArtifacts.Effects.Systems;
|
||||
public sealed class EmpArtifactSystem : EntitySystem
|
||||
{
|
||||
[Dependency] private readonly EmpSystem _emp = default!;
|
||||
[Dependency] private readonly SharedTransformSystem _xform = default!;
|
||||
|
||||
/// <inheritdoc/>
|
||||
public override void Initialize()
|
||||
@@ -17,6 +16,6 @@ public sealed class EmpArtifactSystem : EntitySystem
|
||||
|
||||
private void OnActivate(EntityUid uid, EmpArtifactComponent component, ArtifactActivatedEvent args)
|
||||
{
|
||||
_emp.EmpPulse(_xform.GetMapCoordinates(uid), component.Range, component.EnergyConsumption, component.DisableDuration);
|
||||
_emp.EmpPulse(Transform(uid).MapPosition, component.Range, component.EnergyConsumption, component.DisableDuration);
|
||||
}
|
||||
}
|
||||
@@ -32,7 +32,7 @@ public sealed class SpawnArtifactSystem : EntitySystem
|
||||
if (component.Spawns is not {} spawns)
|
||||
return;
|
||||
|
||||
var artifactCord = _transform.GetMapCoordinates(uid);
|
||||
var artifactCord = Transform(uid).MapPosition;
|
||||
foreach (var spawn in EntitySpawnCollection.GetSpawns(spawns, _random))
|
||||
{
|
||||
var dx = _random.NextFloat(-component.Range, component.Range);
|
||||
|
||||
@@ -19,7 +19,6 @@ public sealed class ThrowArtifactSystem : EntitySystem
|
||||
[Dependency] private readonly EntityLookupSystem _lookup = default!;
|
||||
[Dependency] private readonly ThrowingSystem _throwing = default!;
|
||||
[Dependency] private readonly TileSystem _tile = default!;
|
||||
[Dependency] private readonly SharedTransformSystem _xformSystem = default!;
|
||||
|
||||
/// <inheritdoc/>
|
||||
public override void Initialize()
|
||||
@@ -33,7 +32,7 @@ public sealed class ThrowArtifactSystem : EntitySystem
|
||||
if (_map.TryGetGrid(xform.GridUid, out var grid))
|
||||
{
|
||||
var tiles = grid.GetTilesIntersecting(
|
||||
Box2.CenteredAround(_xformSystem.GetWorldPosition(xform), new Vector2(component.Range * 2, component.Range)));
|
||||
Box2.CenteredAround(xform.WorldPosition, new Vector2(component.Range * 2, component.Range)));
|
||||
|
||||
foreach (var tile in tiles)
|
||||
{
|
||||
@@ -52,7 +51,9 @@ public sealed class ThrowArtifactSystem : EntitySystem
|
||||
&& (phys.CollisionMask & (int) CollisionGroup.GhostImpassable) != 0)
|
||||
continue;
|
||||
|
||||
var foo = _xformSystem.GetWorldPosition(ent) - _xformSystem.GetWorldPosition(xform);
|
||||
var tempXform = Transform(ent);
|
||||
|
||||
var foo = tempXform.MapPosition.Position - xform.MapPosition.Position;
|
||||
_throwing.TryThrow(ent, foo*2, component.ThrowStrength, uid, 0);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user