Make all current admin logs use ToPrettyString
This commit is contained in:
parent
8239d392d4
commit
f6371c6e62
|
|
@ -97,7 +97,7 @@ namespace Content.Server.Actions.Actions
|
|||
|
||||
entMan.EventBus.RaiseLocalEvent(args.Target, eventArgs);
|
||||
|
||||
EntitySystem.Get<AdminLogSystem>().Add(LogType.DisarmedAction, LogImpact.Low, $"{args.Performer:performer} used disarm on {args.Target:target}");
|
||||
EntitySystem.Get<AdminLogSystem>().Add(LogType.DisarmedAction, LogImpact.Low, $"{entMan.ToPrettyString(args.Performer):performer} used disarm on {entMan.ToPrettyString(args.Target):target}");
|
||||
|
||||
// Check if the event has been handled, and if so, do nothing else!
|
||||
if (eventArgs.Handled)
|
||||
|
|
|
|||
|
|
@ -115,7 +115,7 @@ namespace Content.Server.Atmos.Piping.Binary.EntitySystems
|
|||
{
|
||||
pump.Enabled = args.Enabled;
|
||||
_adminLogSystem.Add(LogType.AtmosPowerChanged, LogImpact.Medium,
|
||||
$"{EntityManager.ToPrettyString(args.Session.AttachedEntity!.Value):player} set the power on {EntityManager.ToPrettyString(uid):device} to {args.Enabled}");
|
||||
$"{ToPrettyString(args.Session.AttachedEntity!.Value):player} set the power on {ToPrettyString(uid):device} to {args.Enabled}");
|
||||
DirtyUI(uid, pump);
|
||||
}
|
||||
|
||||
|
|
@ -123,7 +123,7 @@ namespace Content.Server.Atmos.Piping.Binary.EntitySystems
|
|||
{
|
||||
pump.TargetPressure = Math.Clamp(args.Pressure, 0f, Atmospherics.MaxOutputPressure);
|
||||
_adminLogSystem.Add(LogType.AtmosPressureChanged, LogImpact.Medium,
|
||||
$"{EntityManager.ToPrettyString(args.Session.AttachedEntity!.Value):player} set the pressure on {EntityManager.ToPrettyString(uid):device} to {args.Pressure}kPa");
|
||||
$"{ToPrettyString(args.Session.AttachedEntity!.Value):player} set the pressure on {ToPrettyString(uid):device} to {args.Pressure}kPa");
|
||||
DirtyUI(uid, pump);
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -120,7 +120,7 @@ namespace Content.Server.Atmos.Piping.Binary.EntitySystems
|
|||
{
|
||||
pump.Enabled = args.Enabled;
|
||||
_adminLogSystem.Add(LogType.AtmosPowerChanged, LogImpact.Medium,
|
||||
$"{EntityManager.ToPrettyString(args.Session.AttachedEntity!.Value):player} set the power on {EntityManager.ToPrettyString(uid):device} to {args.Enabled}");
|
||||
$"{ToPrettyString(args.Session.AttachedEntity!.Value):player} set the power on {ToPrettyString(uid):device} to {args.Enabled}");
|
||||
DirtyUI(uid, pump);
|
||||
}
|
||||
|
||||
|
|
@ -128,7 +128,7 @@ namespace Content.Server.Atmos.Piping.Binary.EntitySystems
|
|||
{
|
||||
pump.TransferRate = Math.Clamp(args.TransferRate, 0f, Atmospherics.MaxTransferRate);
|
||||
_adminLogSystem.Add(LogType.AtmosVolumeChanged, LogImpact.Medium,
|
||||
$"{EntityManager.ToPrettyString(args.Session.AttachedEntity!.Value):player} set the transfer rate on {EntityManager.ToPrettyString(uid):device} to {args.TransferRate}");
|
||||
$"{ToPrettyString(args.Session.AttachedEntity!.Value):player} set the transfer rate on {ToPrettyString(uid):device} to {args.TransferRate}");
|
||||
DirtyUI(uid, pump);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -114,7 +114,7 @@ namespace Content.Server.Atmos.Piping.Trinary.EntitySystems
|
|||
{
|
||||
filter.Enabled = args.Enabled;
|
||||
_adminLogSystem.Add(LogType.AtmosPowerChanged, LogImpact.Medium,
|
||||
$"{EntityManager.ToPrettyString(args.Session.AttachedEntity!.Value):player} set the power on {EntityManager.ToPrettyString(uid):device} to {args.Enabled}");
|
||||
$"{ToPrettyString(args.Session.AttachedEntity!.Value):player} set the power on {ToPrettyString(uid):device} to {args.Enabled}");
|
||||
|
||||
DirtyUI(uid, filter);
|
||||
}
|
||||
|
|
@ -123,7 +123,7 @@ namespace Content.Server.Atmos.Piping.Trinary.EntitySystems
|
|||
{
|
||||
filter.TransferRate = Math.Clamp(args.Rate, 0f, Atmospherics.MaxTransferRate);
|
||||
_adminLogSystem.Add(LogType.AtmosVolumeChanged, LogImpact.Medium,
|
||||
$"{EntityManager.ToPrettyString(args.Session.AttachedEntity!.Value):player} set the transfer rate on {EntityManager.ToPrettyString(uid):device} to {args.Rate}");
|
||||
$"{ToPrettyString(args.Session.AttachedEntity!.Value):player} set the transfer rate on {ToPrettyString(uid):device} to {args.Rate}");
|
||||
DirtyUI(uid, filter);
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -139,7 +139,7 @@ namespace Content.Server.Atmos.Piping.Trinary.EntitySystems
|
|||
{
|
||||
mixer.Enabled = args.Enabled;
|
||||
_adminLogSystem.Add(LogType.AtmosPowerChanged, LogImpact.Medium,
|
||||
$"{EntityManager.ToPrettyString(args.Session.AttachedEntity!.Value):player} set the power on {EntityManager.ToPrettyString(uid):device} to {args.Enabled}");
|
||||
$"{ToPrettyString(args.Session.AttachedEntity!.Value):player} set the power on {ToPrettyString(uid):device} to {args.Enabled}");
|
||||
DirtyUI(uid, mixer);
|
||||
}
|
||||
|
||||
|
|
@ -147,7 +147,7 @@ namespace Content.Server.Atmos.Piping.Trinary.EntitySystems
|
|||
{
|
||||
mixer.TargetPressure = Math.Clamp(args.Pressure, 0f, Atmospherics.MaxOutputPressure);
|
||||
_adminLogSystem.Add(LogType.AtmosPressureChanged, LogImpact.Medium,
|
||||
$"{EntityManager.ToPrettyString(args.Session.AttachedEntity!.Value):player} set the pressure on {EntityManager.ToPrettyString(uid):device} to {args.Pressure}kPa");
|
||||
$"{ToPrettyString(args.Session.AttachedEntity!.Value):player} set the pressure on {ToPrettyString(uid):device} to {args.Pressure}kPa");
|
||||
DirtyUI(uid, mixer);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -63,7 +63,7 @@ namespace Content.Server.Atmos.Piping.Unary.EntitySystems
|
|||
if (environment is not null)
|
||||
_atmosphereSystem.Merge(environment, canister.Air);
|
||||
|
||||
_adminLogSystem.Add(LogType.CanisterPurged, LogImpact.Medium, $"Canister {uid} purged its contents of {canister.Air} into the environment.");
|
||||
_adminLogSystem.Add(LogType.CanisterPurged, LogImpact.Medium, $"Canister {ToPrettyString(uid)} purged its contents of {canister.Air} into the environment.");
|
||||
canister.Air.Clear();
|
||||
}
|
||||
|
||||
|
|
@ -130,7 +130,7 @@ namespace Content.Server.Atmos.Piping.Unary.EntitySystems
|
|||
if (container.ContainedEntities.Count == 0)
|
||||
return;
|
||||
|
||||
_adminLogSystem.Add(LogType.CanisterTankEjected, LogImpact.Medium, $"Player {args.Session.AttachedEntity:player} ejected tank {container.ContainedEntities[0]:tank} from {uid}");
|
||||
_adminLogSystem.Add(LogType.CanisterTankEjected, LogImpact.Medium, $"Player {ToPrettyString(args.Session.AttachedEntity.GetValueOrDefault()):player} ejected tank {container.ContainedEntities[0]:tank} from {uid}");
|
||||
container.Remove(container.ContainedEntities[0]);
|
||||
}
|
||||
|
||||
|
|
@ -141,7 +141,7 @@ namespace Content.Server.Atmos.Piping.Unary.EntitySystems
|
|||
|
||||
var pressure = Math.Clamp(args.Pressure, canister.MinReleasePressure, canister.MaxReleasePressure);
|
||||
|
||||
_adminLogSystem.Add(LogType.CanisterPressure, LogImpact.Medium, $"{args.Session.AttachedEntity:player} set the release pressure on {uid} to {args.Pressure}");
|
||||
_adminLogSystem.Add(LogType.CanisterPressure, LogImpact.Medium, $"{ToPrettyString(args.Session.AttachedEntity.GetValueOrDefault()):player} set the release pressure on {uid} to {args.Pressure}");
|
||||
|
||||
canister.ReleasePressure = pressure;
|
||||
DirtyUI(uid, canister);
|
||||
|
|
@ -157,7 +157,7 @@ namespace Content.Server.Atmos.Piping.Unary.EntitySystems
|
|||
&& containerManager.TryGetContainer(canister.ContainerName, out var container))
|
||||
impact = container.ContainedEntities.Count != 0 ? LogImpact.Medium : LogImpact.High;
|
||||
|
||||
_adminLogSystem.Add(LogType.CanisterValve, impact, $"{args.Session.AttachedEntity:player} set the valve on {uid} to {args.Valve:valveState}");
|
||||
_adminLogSystem.Add(LogType.CanisterValve, impact, $"{ToPrettyString(args.Session.AttachedEntity.GetValueOrDefault()):player} set the valve on {uid} to {args.Valve:valveState}");
|
||||
|
||||
canister.ReleaseValve = args.Valve;
|
||||
DirtyUI(uid, canister);
|
||||
|
|
@ -278,7 +278,7 @@ namespace Content.Server.Atmos.Piping.Unary.EntitySystems
|
|||
if (!hands.Drop(args.Used, container))
|
||||
return;
|
||||
|
||||
_adminLogSystem.Add(LogType.CanisterTankInserted, LogImpact.Medium, $"Player {args.User:player} inserted tank {container.ContainedEntities[0]} into {canister}");
|
||||
_adminLogSystem.Add(LogType.CanisterTankInserted, LogImpact.Medium, $"Player {ToPrettyString(args.User):player} inserted tank {container.ContainedEntities[0]} into {canister}");
|
||||
|
||||
args.Handled = true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -165,7 +165,7 @@ namespace Content.Server.Body.Systems
|
|||
{
|
||||
var entity = args.SolutionEntity;
|
||||
_logSystem.Add(LogType.ReagentEffect, effect.LogImpact,
|
||||
$"Metabolism effect {effect.GetType().Name} of reagent {args.Reagent.Name:reagent} applied on entity {entity} at {EntityManager.GetComponent<TransformComponent>(entity).Coordinates}");
|
||||
$"Metabolism effect {effect.GetType().Name} of reagent {args.Reagent.Name:reagent} applied on entity {entity} at {Transform(entity).Coordinates}");
|
||||
}
|
||||
|
||||
effect.Effect(args);
|
||||
|
|
|
|||
|
|
@ -15,10 +15,10 @@ namespace Content.Server.Chemistry.EntitySystems
|
|||
{
|
||||
base.OnReaction(solution, reaction, randomReagent, Owner, unitReactions);
|
||||
|
||||
var coordinates = EntityManager.GetComponent<TransformComponent>(Owner).Coordinates;
|
||||
var coordinates = Transform(Owner).Coordinates;
|
||||
|
||||
_logSystem.Add(LogType.ChemicalReaction, reaction.Impact,
|
||||
$"Chemical reaction {reaction.ID} occurred with strength {unitReactions:strength} on entity {Owner} at {coordinates}");
|
||||
$"Chemical reaction {reaction.ID} occurred with strength {unitReactions:strength} on entity {ToPrettyString(Owner)} at {coordinates}");
|
||||
|
||||
SoundSystem.Play(Filter.Pvs(Owner, entityManager:EntityManager), reaction.Sound.GetSound(), Owner);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -138,9 +138,9 @@ namespace Content.Server.GameTicking
|
|||
_stationSystem.TryAssignJobToStation(station, jobPrototype);
|
||||
|
||||
if (lateJoin)
|
||||
_adminLogSystem.Add(LogType.LateJoin, LogImpact.Medium, $"Player {player.Name} late joined as {character.Name:characterName} on station {_stationSystem.StationInfo[station].Name:stationName} with {mob} as a {job.Name:jobName}.");
|
||||
_adminLogSystem.Add(LogType.LateJoin, LogImpact.Medium, $"Player {player.Name} late joined as {character.Name:characterName} on station {_stationSystem.StationInfo[station].Name:stationName} with {ToPrettyString(mob)} as a {job.Name:jobName}.");
|
||||
else
|
||||
_adminLogSystem.Add(LogType.RoundStartJoin, LogImpact.Medium, $"Player {player.Name} joined as {character.Name:characterName} on station {_stationSystem.StationInfo[station].Name:stationName} with {mob} as a {job.Name:jobName}.");
|
||||
_adminLogSystem.Add(LogType.RoundStartJoin, LogImpact.Medium, $"Player {player.Name} joined as {character.Name:characterName} on station {_stationSystem.StationInfo[station].Name:stationName} with {ToPrettyString(mob)} as a {job.Name:jobName}.");
|
||||
|
||||
Preset?.OnSpawnPlayerCompleted(player, mob, lateJoin);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -394,7 +394,7 @@ namespace Content.Server.Interaction
|
|||
// all interactions should only happen when in range / unobstructed, so no range check is needed
|
||||
var message = new InteractHandEvent(user, target);
|
||||
RaiseLocalEvent(target, message);
|
||||
_adminLogSystem.Add(LogType.InteractHand, LogImpact.Low, $"{user} interacted with {target}");
|
||||
_adminLogSystem.Add(LogType.InteractHand, LogImpact.Low, $"{ToPrettyString(user)} interacted with {ToPrettyString(target)}");
|
||||
if (message.Handled)
|
||||
return;
|
||||
|
||||
|
|
@ -482,7 +482,7 @@ namespace Content.Server.Interaction
|
|||
|
||||
if (ev.Handled)
|
||||
{
|
||||
_adminLogSystem.Add(LogType.AttackArmedWide, LogImpact.Medium, $"{user} wide attacked with {item} at {coordinates}");
|
||||
_adminLogSystem.Add(LogType.AttackArmedWide, LogImpact.Medium, $"{ToPrettyString(user)} wide attacked with {ToPrettyString(item)} at {coordinates}");
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
|
@ -496,12 +496,12 @@ namespace Content.Server.Interaction
|
|||
if (targetUid != default)
|
||||
{
|
||||
_adminLogSystem.Add(LogType.AttackArmedClick, LogImpact.Medium,
|
||||
$"{user} attacked {targetUid} with {item} at {coordinates}");
|
||||
$"{ToPrettyString(user)} attacked {ToPrettyString(targetUid)} with {ToPrettyString(item)} at {coordinates}");
|
||||
}
|
||||
else
|
||||
{
|
||||
_adminLogSystem.Add(LogType.AttackArmedClick, LogImpact.Medium,
|
||||
$"{user} attacked with {item} at {coordinates}");
|
||||
$"{ToPrettyString(user)} attacked with {ToPrettyString(item)} at {coordinates}");
|
||||
}
|
||||
|
||||
return;
|
||||
|
|
@ -534,12 +534,12 @@ namespace Content.Server.Interaction
|
|||
if (targetUid != default)
|
||||
{
|
||||
_adminLogSystem.Add(LogType.AttackUnarmedClick, LogImpact.Medium,
|
||||
$"{user} attacked {targetUid} at {coordinates}");
|
||||
$"{ToPrettyString(user)} attacked {ToPrettyString(targetUid)} at {coordinates}");
|
||||
}
|
||||
else
|
||||
{
|
||||
_adminLogSystem.Add(LogType.AttackUnarmedClick, LogImpact.Medium,
|
||||
$"{user} attacked at {coordinates}");
|
||||
$"{ToPrettyString(user)} attacked at {coordinates}");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -379,7 +379,7 @@ namespace Content.Server.Nutrition.EntitySystems
|
|||
});
|
||||
|
||||
// logging
|
||||
_logSystem.Add(LogType.ForceFeed, LogImpact.Medium, $"{userUid} is forcing {targetUid} to drink {uid}");
|
||||
_logSystem.Add(LogType.ForceFeed, LogImpact.Medium, $"{ToPrettyString(userUid)} is forcing {ToPrettyString(targetUid)} to drink {ToPrettyString(uid)}");
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -325,7 +325,7 @@ namespace Content.Server.Nutrition.EntitySystems
|
|||
});
|
||||
|
||||
// logging
|
||||
_logSystem.Add(LogType.ForceFeed, LogImpact.Medium, $"{user} is forcing {target} to eat {uid}");
|
||||
_logSystem.Add(LogType.ForceFeed, LogImpact.Medium, $"{ToPrettyString(user)} is forcing {ToPrettyString(target)} to eat {ToPrettyString(uid)}");
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -58,7 +58,7 @@ namespace Content.Server.Projectiles
|
|||
|
||||
if (dmg is not null && EntityManager.EntityExists(component.Shooter))
|
||||
_adminLogSystem.Add(LogType.BulletHit, LogImpact.Low,
|
||||
$"Projectile {component.Owner} shot by {component.Shooter:shooter} hit {otherEntity} and dealt {dmg.Total} damage");
|
||||
$"Projectile {ToPrettyString(component.Owner)} shot by {ToPrettyString(component.Shooter):shooter} hit {ToPrettyString(otherEntity)} and dealt {dmg.Total} damage");
|
||||
}
|
||||
|
||||
// Damaging it can delete it
|
||||
|
|
|
|||
|
|
@ -95,7 +95,7 @@ namespace Content.Server.RoundEnd
|
|||
|
||||
if (requester != default)
|
||||
{
|
||||
_adminLog.Add(LogType.ShuttleCalled, LogImpact.High, $"Shuttle called by {requester}");
|
||||
_adminLog.Add(LogType.ShuttleCalled, LogImpact.High, $"Shuttle called by {ToPrettyString(requester.Value)}");
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
@ -128,7 +128,7 @@ namespace Content.Server.RoundEnd
|
|||
|
||||
if (requester != default)
|
||||
{
|
||||
_adminLog.Add(LogType.ShuttleRecalled, LogImpact.High, $"Shuttle recalled by {requester}");
|
||||
_adminLog.Add(LogType.ShuttleRecalled, LogImpact.High, $"Shuttle recalled by {ToPrettyString(requester.Value)}");
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
|||
|
|
@ -53,7 +53,7 @@ namespace Content.Server.Stunnable
|
|||
}
|
||||
}
|
||||
|
||||
_adminLogSystem.Add(LogType.DisarmedKnockdown, LogImpact.Medium, $"{args.Source:performer} knocked down {args.Target:target}");
|
||||
_adminLogSystem.Add(LogType.DisarmedKnockdown, LogImpact.Medium, $"{ToPrettyString(args.Source):performer} knocked down {ToPrettyString(args.Target):target}");
|
||||
|
||||
args.Handled = true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -187,7 +187,7 @@ namespace Content.Shared.Chemistry.Reaction
|
|||
{
|
||||
var entity = args.SolutionEntity;
|
||||
_logSystem.Add(LogType.ReagentEffect, effect.LogImpact,
|
||||
$"Reaction effect {effect.GetType().Name} of reaction ${reaction.ID:reaction} applied on entity {entity} at {EntityManager.GetComponent<TransformComponent>(entity).Coordinates}");
|
||||
$"Reaction effect {effect.GetType().Name} of reaction ${reaction.ID:reaction} applied on entity {ToPrettyString(entity)} at {Transform(entity).Coordinates}");
|
||||
}
|
||||
|
||||
effect.Effect(args);
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@ namespace Content.Shared.Chemistry
|
|||
{
|
||||
var entity = args.SolutionEntity;
|
||||
_logSystem.Add(LogType.ReagentEffect, effect.LogImpact,
|
||||
$"Reactive effect {effect.GetType().Name} of reagent {reagent.ID:reagent} with method {method} applied on entity {entity} at {EntityManager.GetComponent<TransformComponent>(entity).Coordinates}");
|
||||
$"Reactive effect {effect.GetType().Name} of reagent {reagent.ID:reagent} with method {method} applied on entity {ToPrettyString(entity)} at {Transform(entity).Coordinates}");
|
||||
}
|
||||
|
||||
effect.Effect(args);
|
||||
|
|
@ -94,7 +94,7 @@ namespace Content.Shared.Chemistry
|
|||
{
|
||||
var entity = args.SolutionEntity;
|
||||
_logSystem.Add(LogType.ReagentEffect, effect.LogImpact,
|
||||
$"Reactive effect {effect.GetType().Name} of {entity} using reagent {reagent.ID} with method {method} at {EntityManager.GetComponent<TransformComponent>(entity).Coordinates}");
|
||||
$"Reactive effect {effect.GetType().Name} of {ToPrettyString(entity)} using reagent {reagent.ID} with method {method} at {Transform(entity).Coordinates}");
|
||||
}
|
||||
|
||||
effect.Effect(args);
|
||||
|
|
|
|||
|
|
@ -123,7 +123,7 @@ namespace Content.Shared.Chemistry.Reagent
|
|||
{
|
||||
var entity = args.SolutionEntity;
|
||||
EntitySystem.Get<SharedAdminLogSystem>().Add(LogType.ReagentEffect, plantMetabolizable.LogImpact,
|
||||
$"Plant metabolism effect {plantMetabolizable.GetType().Name:effect} of reagent {ID} applied on entity {entity} at {IoCManager.Resolve<IEntityManager>().GetComponent<TransformComponent>(entity).Coordinates}");
|
||||
$"Plant metabolism effect {plantMetabolizable.GetType().Name:effect} of reagent {ID} applied on entity {entMan.ToPrettyString(entity)} at {entMan.GetComponent<TransformComponent>(entity).Coordinates}");
|
||||
plantMetabolizable.Effect(args);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -673,7 +673,7 @@ namespace Content.Shared.Hands.Components
|
|||
|
||||
HandlePickupAnimation(entity);
|
||||
PutEntityIntoHand(hand, entity);
|
||||
EntitySystem.Get<SharedAdminLogSystem>().Add(LogType.Pickup, LogImpact.Low, $"{Owner} picked up {entity}");
|
||||
EntitySystem.Get<SharedAdminLogSystem>().Add(LogType.Pickup, LogImpact.Low, $"{_entMan.ToPrettyString(Owner)} picked up {_entMan.ToPrettyString(entity)}");
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -468,7 +468,7 @@ namespace Content.Shared.Interaction
|
|||
RaiseLocalEvent(used, activateMsg);
|
||||
if (activateMsg.Handled)
|
||||
{
|
||||
_adminLogSystem.Add(LogType.InteractActivate, LogImpact.Low, $"{user} activated {used}");
|
||||
_adminLogSystem.Add(LogType.InteractActivate, LogImpact.Low, $"{ToPrettyString(user)} activated {ToPrettyString(used)}");
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
@ -477,7 +477,7 @@ namespace Content.Shared.Interaction
|
|||
|
||||
var activateEventArgs = new ActivateEventArgs(user, used);
|
||||
activateComp.Activate(activateEventArgs);
|
||||
_adminLogSystem.Add(LogType.InteractActivate, LogImpact.Low, $"{user} activated {used}"); // No way to check success.
|
||||
_adminLogSystem.Add(LogType.InteractActivate, LogImpact.Low, $"{ToPrettyString(user)} activated {ToPrettyString(used)}"); // No way to check success.
|
||||
}
|
||||
#endregion
|
||||
|
||||
|
|
@ -556,7 +556,7 @@ namespace Content.Shared.Interaction
|
|||
RaiseLocalEvent(thrown, throwMsg);
|
||||
if (throwMsg.Handled)
|
||||
{
|
||||
_adminLogSystem.Add(LogType.Throw, LogImpact.Low,$"{user} threw {thrown}");
|
||||
_adminLogSystem.Add(LogType.Throw, LogImpact.Low,$"{ToPrettyString(user)} threw {ToPrettyString(thrown)}");
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
@ -568,7 +568,7 @@ namespace Content.Shared.Interaction
|
|||
{
|
||||
comp.Thrown(args);
|
||||
}
|
||||
_adminLogSystem.Add(LogType.Throw, LogImpact.Low,$"{user} threw {thrown}");
|
||||
_adminLogSystem.Add(LogType.Throw, LogImpact.Low,$"{ToPrettyString(user)} threw {ToPrettyString(thrown)}");
|
||||
}
|
||||
#endregion
|
||||
|
||||
|
|
@ -677,7 +677,7 @@ namespace Content.Shared.Interaction
|
|||
RaiseLocalEvent(item, dropMsg);
|
||||
if (dropMsg.Handled)
|
||||
{
|
||||
_adminLogSystem.Add(LogType.Drop, LogImpact.Low, $"{user} dropped {item}");
|
||||
_adminLogSystem.Add(LogType.Drop, LogImpact.Low, $"{ToPrettyString(user)} dropped {ToPrettyString(item)}");
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
@ -690,7 +690,7 @@ namespace Content.Shared.Interaction
|
|||
{
|
||||
comp.Dropped(new DroppedEventArgs(user));
|
||||
}
|
||||
_adminLogSystem.Add(LogType.Drop, LogImpact.Low, $"{user} dropped {item}");
|
||||
_adminLogSystem.Add(LogType.Drop, LogImpact.Low, $"{ToPrettyString(user)} dropped {ToPrettyString(item)}");
|
||||
}
|
||||
#endregion
|
||||
|
||||
|
|
|
|||
|
|
@ -106,7 +106,7 @@ namespace Content.Shared.Slippery
|
|||
PlaySound(component);
|
||||
}
|
||||
|
||||
_adminLog.Add(LogType.Slip, LogImpact.Low, $"{otherBody.Owner} slipped on collision with {component.Owner}");
|
||||
_adminLog.Add(LogType.Slip, LogImpact.Low, $"{ToPrettyString(otherBody.Owner)} slipped on collision with {ToPrettyString(component.Owner)}");
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -128,7 +128,7 @@ namespace Content.Shared.Throwing
|
|||
|
||||
// Assume it's uninteresting if it has no thrower. For now anyway.
|
||||
if (thrownItem.Thrower is not null)
|
||||
_adminLogSystem.Add(LogType.Landed, LogImpact.Low, $"{landing} thrown by {thrownItem.Thrower:thrower} landed.");
|
||||
_adminLogSystem.Add(LogType.Landed, LogImpact.Low, $"{ToPrettyString(landing)} thrown by {ToPrettyString(thrownItem.Thrower.Value):thrower} landed.");
|
||||
|
||||
var landMsg = new LandEvent {User = thrownItem.Thrower};
|
||||
RaiseLocalEvent(landing, landMsg, false);
|
||||
|
|
@ -141,7 +141,7 @@ namespace Content.Shared.Throwing
|
|||
{
|
||||
if (user is not null)
|
||||
_adminLogSystem.Add(LogType.ThrowHit, LogImpact.Low,
|
||||
$"{thrown.Owner:thrown} thrown by {user:thrower} hit {target.Owner:target}.");
|
||||
$"{ToPrettyString(thrown.Owner):thrown} thrown by {ToPrettyString(user.Value):thrower} hit {ToPrettyString(target.Owner):target}.");
|
||||
// TODO: Just pass in the bodies directly
|
||||
RaiseLocalEvent(target.Owner, new ThrowHitByEvent(user, thrown.Owner, target.Owner));
|
||||
RaiseLocalEvent(thrown.Owner, new ThrowDoHitEvent(user, thrown.Owner, target.Owner));
|
||||
|
|
|
|||
|
|
@ -139,10 +139,10 @@ namespace Content.Shared.Verbs
|
|||
// then log with entity information
|
||||
if (used != null)
|
||||
_logSystem.Add(LogType.Verb, verb.Impact,
|
||||
$"{user} {logText} {target} while holding {used}");
|
||||
$"{ToPrettyString(user)} {logText} {ToPrettyString(target)} while holding {ToPrettyString(used.Value)}");
|
||||
else
|
||||
_logSystem.Add(LogType.Verb, verb.Impact,
|
||||
$"{user} {logText} {target}");
|
||||
$"{ToPrettyString(user)} {logText} {ToPrettyString(target)}");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue