Mobstate Refactor (#13389)
Refactors mobstate and moves mob health thresholds to their own component Co-authored-by: DrSmugleaf <drsmugleaf@gmail.com>
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
using Content.Server.Standing;
|
||||
using Content.Shared.Hands;
|
||||
using Content.Shared.MobState;
|
||||
using Content.Shared.Mobs;
|
||||
using Content.Shared.Vehicle.Components;
|
||||
using Robust.Shared.GameStates;
|
||||
|
||||
@@ -48,7 +48,7 @@ namespace Content.Server.Vehicle
|
||||
/// </summary>
|
||||
private void OnMobStateChanged(EntityUid uid, RiderComponent rider, MobStateChangedEvent args)
|
||||
{
|
||||
if (args.CurrentMobState is DamageState.Critical or DamageState.Dead)
|
||||
if (args.NewMobState is MobState.Critical or MobState.Dead)
|
||||
{
|
||||
UnbuckleFromVehicle(uid);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user