Remove most usages of obsolete TransformComponent methods (#19571)

This commit is contained in:
Visne
2023-08-30 04:05:19 +02:00
committed by GitHub
parent 3ba60835ec
commit 1416942bea
91 changed files with 312 additions and 221 deletions

View File

@@ -29,6 +29,7 @@ public sealed class BodySystem : SharedBodySystem
[Dependency] private readonly MobStateSystem _mobState = default!;
[Dependency] private readonly SharedAudioSystem _audio = default!;
[Dependency] private readonly MindSystem _mindSystem = default!;
[Dependency] private readonly SharedTransformSystem _transform = default!;
public override void Initialize()
{
@@ -126,7 +127,7 @@ public sealed class BodySystem : SharedBodySystem
return;
// Don't microwave animals, kids
Transform(uid).AttachToGridOrMap();
_transform.AttachToGridOrMap(uid);
GibBody(uid, false, component);
args.Handled = true;
@@ -208,7 +209,7 @@ public sealed class BodySystem : SharedBodySystem
else
{
cont.Remove(ent, EntityManager, force: true);
Transform(ent).Coordinates = coordinates;
_transform.SetCoordinates(ent, coordinates);
ent.RandomOffset(0.25f);
}
}