Fix and update VehicleSystem.cs (#15284)

This commit is contained in:
Daniil Sikinami
2023-04-15 09:02:03 +03:00
committed by GitHub
parent 08e5d336fc
commit ddbac96ffa
4 changed files with 60 additions and 24 deletions

View File

@@ -7,6 +7,7 @@ using Content.Shared.Movement.Components;
using Content.Shared.Movement.Systems;
using Content.Shared.Vehicle;
using Content.Shared.Vehicle.Components;
using Robust.Server.GameObjects;
using Robust.Shared.Audio;
using Robust.Shared.Physics.Systems;
using Robust.Shared.Player;
@@ -89,7 +90,8 @@ namespace Content.Server.Vehicle
// Update appearance stuff, add actions
UpdateBuckleOffset(Transform(uid), component);
UpdateDrawDepth(uid, GetDrawDepth(Transform(uid), component.NorthOnly));
if (TryComp<InputMoverComponent>(uid, out var mover))
UpdateDrawDepth(uid, GetDrawDepth(Transform(uid), component, mover.RelativeRotation.Degrees));
if (TryComp<ActionsComponent>(args.BuckledEntity, out var actions) && TryComp<UnpoweredFlashlightComponent>(uid, out var flashlight))
{