diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 69c5f0138f..21c3070b80 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -27,7 +27,7 @@ /Content.YAMLLinter @DrSmugleaf /Content.Shared/Damage/ @DrSmugleaf -/Content.*/Anomaly/ @EmoGarbage404 +/Content.*/Anomaly/ @EmoGarbage404 @TheShuEd /Content.*/Lathe/ @EmoGarbage404 /Content.*/Materials/ @EmoGarbage404 /Content.*/Mech/ @EmoGarbage404 @@ -35,7 +35,7 @@ /Content.*/Stack/ @EmoGarbage404 /Content.*/Xenoarchaeology/ @EmoGarbage404 /Content.*/Zombies/ @EmoGarbage404 -/Resources/Prototypes/Entities/Structures/Specific/anomalies.yml @EmoGarbage404 +/Resources/Prototypes/Entities/Structures/Specific/anomalies.yml @EmoGarbage404 @TheShuEd /Resources/Prototypes/Research/ @EmoGarbage404 /Content.*/Forensics/ @ficcialfaint diff --git a/Content.Client/Gravity/GravitySystem.Shake.cs b/Content.Client/Gravity/GravitySystem.Shake.cs index c4356588d3..9b9918ca3e 100644 --- a/Content.Client/Gravity/GravitySystem.Shake.cs +++ b/Content.Client/Gravity/GravitySystem.Shake.cs @@ -25,7 +25,7 @@ public sealed partial class GravitySystem { var localPlayer = _playerManager.LocalEntity; - if (!TryComp(localPlayer, out var xform) || + if (!TryComp(localPlayer, out TransformComponent? xform) || xform.GridUid != uid && xform.MapUid != uid) { return; @@ -46,7 +46,7 @@ public sealed partial class GravitySystem var localPlayer = _playerManager.LocalEntity; - if (!TryComp(localPlayer, out var xform)) + if (!TryComp(localPlayer, out TransformComponent? xform)) return; if (xform.GridUid != uid || diff --git a/Content.Client/Guidebook/Controls/GuideReagentEmbed.xaml b/Content.Client/Guidebook/Controls/GuideReagentEmbed.xaml index f46e319abe..73a17e9bcc 100644 --- a/Content.Client/Guidebook/Controls/GuideReagentEmbed.xaml +++ b/Content.Client/Guidebook/Controls/GuideReagentEmbed.xaml @@ -47,6 +47,17 @@ + + + + + + + + diff --git a/Content.Client/Guidebook/Controls/GuideReagentEmbed.xaml.cs b/Content.Client/Guidebook/Controls/GuideReagentEmbed.xaml.cs index 537494933b..87931bf845 100644 --- a/Content.Client/Guidebook/Controls/GuideReagentEmbed.xaml.cs +++ b/Content.Client/Guidebook/Controls/GuideReagentEmbed.xaml.cs @@ -157,6 +157,39 @@ public sealed partial class GuideReagentEmbed : BoxContainer, IDocumentTag, ISea } #endregion + #region PlantMetabolisms + if (_chemistryGuideData.ReagentGuideRegistry.TryGetValue(reagent.ID, out var guideEntryRegistryPlant) && + guideEntryRegistryPlant.PlantMetabolisms != null && + guideEntryRegistryPlant.PlantMetabolisms.Count > 0) + { + PlantMetabolismsDescriptionContainer.Children.Clear(); + var metabolismLabel = new RichTextLabel(); + metabolismLabel.SetMarkup(Loc.GetString("guidebook-reagent-plant-metabolisms-rate")); + var descriptionLabel = new RichTextLabel + { + Margin = new Thickness(25, 0, 10, 0) + }; + var descMsg = new FormattedMessage(); + var descriptionsCount = guideEntryRegistryPlant.PlantMetabolisms.Count; + var i = 0; + foreach (var effectString in guideEntryRegistryPlant.PlantMetabolisms) + { + descMsg.AddMarkup(effectString); + i++; + if (i < descriptionsCount) + descMsg.PushNewline(); + } + descriptionLabel.SetMessage(descMsg); + + PlantMetabolismsDescriptionContainer.AddChild(metabolismLabel); + PlantMetabolismsDescriptionContainer.AddChild(descriptionLabel); + } + else + { + PlantMetabolismsContainer.Visible = false; + } + #endregion + GenerateSources(reagent); FormattedMessage description = new(); diff --git a/Content.Client/Maps/GridDraggingSystem.cs b/Content.Client/Maps/GridDraggingSystem.cs index 16357c8983..e82786847e 100644 --- a/Content.Client/Maps/GridDraggingSystem.cs +++ b/Content.Client/Maps/GridDraggingSystem.cs @@ -61,7 +61,7 @@ public sealed class GridDraggingSystem : SharedGridDraggingSystem { if (_dragging == null) return; - if (_lastMousePosition != null && TryComp(_dragging.Value, out var xform) && + if (_lastMousePosition != null && TryComp(_dragging.Value, out TransformComponent? xform) && TryComp(_dragging.Value, out var body) && xform.MapID == _lastMousePosition.Value.MapId) { @@ -104,7 +104,7 @@ public sealed class GridDraggingSystem : SharedGridDraggingSystem StartDragging(gridUid, Transform(gridUid).InvWorldMatrix.Transform(mousePos.Position)); } - if (!TryComp(_dragging, out var xform)) + if (!TryComp(_dragging, out TransformComponent? xform)) { StopDragging(); return; diff --git a/Content.Client/Salvage/SalvageSystem.cs b/Content.Client/Salvage/SalvageSystem.cs index fb305c5fdc..e1bce367ca 100644 --- a/Content.Client/Salvage/SalvageSystem.cs +++ b/Content.Client/Salvage/SalvageSystem.cs @@ -38,7 +38,7 @@ public sealed class SalvageSystem : SharedSalvageSystem var player = _playerManager.LocalEntity; - if (!TryComp(player, out var xform) || + if (!TryComp(player, out TransformComponent? xform) || !TryComp(xform.MapUid, out var expedition) || expedition.Stage < ExpeditionStage.MusicCountdown) { diff --git a/Content.Client/Sprite/SpriteFadeSystem.cs b/Content.Client/Sprite/SpriteFadeSystem.cs index d9584b60a6..676a6e583d 100644 --- a/Content.Client/Sprite/SpriteFadeSystem.cs +++ b/Content.Client/Sprite/SpriteFadeSystem.cs @@ -45,7 +45,7 @@ public sealed class SpriteFadeSystem : EntitySystem var spriteQuery = GetEntityQuery(); var change = ChangeRate * frameTime; - if (TryComp(player, out var playerXform) && + if (TryComp(player, out TransformComponent? playerXform) && _stateManager.CurrentState is GameplayState state && spriteQuery.TryGetComponent(player, out var playerSprite)) { diff --git a/Content.Client/Weapons/Misc/TetherGunSystem.cs b/Content.Client/Weapons/Misc/TetherGunSystem.cs index 634dbd24e7..398aeabb83 100644 --- a/Content.Client/Weapons/Misc/TetherGunSystem.cs +++ b/Content.Client/Weapons/Misc/TetherGunSystem.cs @@ -82,7 +82,7 @@ public sealed class TetherGunSystem : SharedTetherGunSystem const float BufferDistance = 0.1f; - if (TryComp(gun.TetherEntity, out var tetherXform) && + if (TryComp(gun.TetherEntity, out TransformComponent? tetherXform) && tetherXform.Coordinates.TryDistance(EntityManager, TransformSystem, coords, out var distance) && distance < BufferDistance) { diff --git a/Content.IntegrationTests/Tests/Minds/GhostTests.cs b/Content.IntegrationTests/Tests/Minds/GhostTests.cs index ad9d53a70d..7a156e71e4 100644 --- a/Content.IntegrationTests/Tests/Minds/GhostTests.cs +++ b/Content.IntegrationTests/Tests/Minds/GhostTests.cs @@ -156,4 +156,20 @@ public sealed class GhostTests await data.Pair.CleanReturnAsync(); } + [Test] + public async Task TestGhostGridNotTerminating() + { + var data = await SetupData(); + + Assert.DoesNotThrowAsync(async () => + { + // Delete the grid + await data.Server.WaitPost(() => data.SEntMan.DeleteEntity(data.MapData.Grid.Owner)); + }); + + await data.Pair.RunTicksSync(5); + + await data.Pair.CleanReturnAsync(); + } + } diff --git a/Content.Server/Atmos/EntitySystems/AtmosphereSystem.Commands.cs b/Content.Server/Atmos/EntitySystems/AtmosphereSystem.Commands.cs index f711b235af..5a41a7567b 100644 --- a/Content.Server/Atmos/EntitySystems/AtmosphereSystem.Commands.cs +++ b/Content.Server/Atmos/EntitySystems/AtmosphereSystem.Commands.cs @@ -165,7 +165,7 @@ public sealed partial class AtmosphereSystem foreach (var grid in _mapManager.GetAllGrids(playerMap.Value).OrderBy(o => o.Owner)) { var uid = grid.Owner; - if (!TryComp(uid, out var gridXform)) + if (!TryComp(uid, out TransformComponent? gridXform)) continue; options.Add(new CompletionOption(uid.ToString(), $"{MetaData(uid).EntityName} - Map {gridXform.MapID}")); diff --git a/Content.Server/Bible/BibleSystem.cs b/Content.Server/Bible/BibleSystem.cs index 0c60e40dac..2cb0ac1dd7 100644 --- a/Content.Server/Bible/BibleSystem.cs +++ b/Content.Server/Bible/BibleSystem.cs @@ -167,7 +167,7 @@ namespace Content.Server.Bible { Act = () => { - if (!TryComp(args.User, out var userXform)) + if (!TryComp(args.User, out TransformComponent? userXform)) return; AttemptSummon((uid, component), args.User, userXform); diff --git a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustAttribute.cs b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustAttribute.cs index f43b4828f9..80c5ca5cf2 100644 --- a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustAttribute.cs +++ b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustAttribute.cs @@ -15,6 +15,18 @@ namespace Content.Server.Chemistry.ReagentEffects.PlantMetabolism [DataField] public float Prob { get; protected set; } = 1; // = (80); + /// + /// Localisation key for the name of the adjusted attribute. Used for guidebook descriptions. + /// + [DataField] + public abstract string GuidebookAttributeName { get; set; } + + /// + /// Whether the attribute in question is a good thing. Used for guidebook descriptions to determine the color of the number. + /// + [DataField] + public virtual bool GuidebookIsAttributePositive { get; protected set; } = true; + /// /// Checks if the plant holder can metabolize the reagent or not. Checks if it has an alive plant by default. /// @@ -40,6 +52,18 @@ namespace Content.Server.Chemistry.ReagentEffects.PlantMetabolism return !(Prob <= 0f) && IoCManager.Resolve().Prob(Prob); } - protected override string? ReagentEffectGuidebookText(IPrototypeManager prototype, IEntitySystemManager entSys) => Loc.GetString("reagent-effect-guidebook-missing", ("chance", Probability)); + protected override string? ReagentEffectGuidebookText(IPrototypeManager prototype, IEntitySystemManager entSys) + { + string color; + if (GuidebookIsAttributePositive ^ Amount < 0.0) + { + color = "green"; + } + else + { + color = "red"; + } + return Loc.GetString("reagent-effect-guidebook-plant-attribute", ("attribute", Loc.GetString(GuidebookAttributeName)), ("amount", Amount.ToString("0.00")), ("colorName", color), ("chance", Probability)); + } } } diff --git a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustHealth.cs b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustHealth.cs index f03464469e..af74c17de7 100644 --- a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustHealth.cs +++ b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustHealth.cs @@ -5,6 +5,9 @@ namespace Content.Server.Chemistry.ReagentEffects.PlantMetabolism { public sealed partial class PlantAdjustHealth : PlantAdjustAttribute { + public override string GuidebookAttributeName { get; set; } = "plant-attribute-health"; + + public override void Effect(ReagentEffectArgs args) { if (!CanMetabolize(args.SolutionEntity, out var plantHolderComp, args.EntityManager)) diff --git a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustMutationLevel.cs b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustMutationLevel.cs index 8c8d04765a..cf0983bc51 100644 --- a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustMutationLevel.cs +++ b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustMutationLevel.cs @@ -4,6 +4,9 @@ namespace Content.Server.Chemistry.ReagentEffects.PlantMetabolism { public sealed partial class PlantAdjustMutationLevel : PlantAdjustAttribute { + public override string GuidebookAttributeName { get; set; } = "plant-attribute-mutation-level"; + + public override void Effect(ReagentEffectArgs args) { if (!CanMetabolize(args.SolutionEntity, out var plantHolderComp, args.EntityManager)) diff --git a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustMutationMod.cs b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustMutationMod.cs index af4a00a044..b43e885388 100644 --- a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustMutationMod.cs +++ b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustMutationMod.cs @@ -6,6 +6,8 @@ namespace Content.Server.Chemistry.ReagentEffects.PlantMetabolism [UsedImplicitly] public sealed partial class PlantAdjustMutationMod : PlantAdjustAttribute { + public override string GuidebookAttributeName { get; set; } = "plant-attribute-mutation-mod"; + public override void Effect(ReagentEffectArgs args) { if (!CanMetabolize(args.SolutionEntity, out var plantHolderComp, args.EntityManager)) diff --git a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustNutrition.cs b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustNutrition.cs index 900121412e..68bb59870d 100644 --- a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustNutrition.cs +++ b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustNutrition.cs @@ -7,6 +7,8 @@ namespace Content.Server.Chemistry.ReagentEffects.PlantMetabolism [UsedImplicitly] public sealed partial class PlantAdjustNutrition : PlantAdjustAttribute { + public override string GuidebookAttributeName { get; set; } = "plant-attribute-nutrition"; + public override void Effect(ReagentEffectArgs args) { if (!CanMetabolize(args.SolutionEntity, out var plantHolderComp, args.EntityManager, mustHaveAlivePlant: false)) diff --git a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustPests.cs b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustPests.cs index 27729b4b2c..9e9787d030 100644 --- a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustPests.cs +++ b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustPests.cs @@ -6,6 +6,9 @@ namespace Content.Server.Chemistry.ReagentEffects.PlantMetabolism [UsedImplicitly] public sealed partial class PlantAdjustPests : PlantAdjustAttribute { + public override string GuidebookAttributeName { get; set; } = "plant-attribute-pests"; + public override bool GuidebookIsAttributePositive { get; protected set; } = false; + public override void Effect(ReagentEffectArgs args) { if (!CanMetabolize(args.SolutionEntity, out var plantHolderComp, args.EntityManager)) diff --git a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustToxins.cs b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustToxins.cs index 35130238ad..2279f74910 100644 --- a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustToxins.cs +++ b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustToxins.cs @@ -6,6 +6,9 @@ namespace Content.Server.Chemistry.ReagentEffects.PlantMetabolism [UsedImplicitly] public sealed partial class PlantAdjustToxins : PlantAdjustAttribute { + public override string GuidebookAttributeName { get; set; } = "plant-attribute-toxins"; + public override bool GuidebookIsAttributePositive { get; protected set; } = false; + public override void Effect(ReagentEffectArgs args) { if (!CanMetabolize(args.SolutionEntity, out var plantHolderComp, args.EntityManager)) diff --git a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustWater.cs b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustWater.cs index 71b4670dc6..a1c184d3b7 100644 --- a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustWater.cs +++ b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustWater.cs @@ -7,6 +7,8 @@ namespace Content.Server.Chemistry.ReagentEffects.PlantMetabolism [UsedImplicitly] public sealed partial class PlantAdjustWater : PlantAdjustAttribute { + public override string GuidebookAttributeName { get; set; } = "plant-attribute-water"; + public override void Effect(ReagentEffectArgs args) { if (!CanMetabolize(args.SolutionEntity, out var plantHolderComp, args.EntityManager, mustHaveAlivePlant: false)) diff --git a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustWeeds.cs b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustWeeds.cs index 6184b95adb..82958e97a1 100644 --- a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustWeeds.cs +++ b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAdjustWeeds.cs @@ -6,6 +6,9 @@ namespace Content.Server.Chemistry.ReagentEffects.PlantMetabolism [UsedImplicitly] public sealed partial class PlantAdjustWeeds : PlantAdjustAttribute { + public override string GuidebookAttributeName { get; set; } = "plant-attribute-weeds"; + public override bool GuidebookIsAttributePositive { get; protected set; } = false; + public override void Effect(ReagentEffectArgs args) { if (!CanMetabolize(args.SolutionEntity, out var plantHolderComp, args.EntityManager)) diff --git a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAffectGrowth.cs b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAffectGrowth.cs index 54ec628fdc..e92b1954c0 100644 --- a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAffectGrowth.cs +++ b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantAffectGrowth.cs @@ -7,6 +7,8 @@ namespace Content.Server.Chemistry.ReagentEffects.PlantMetabolism [UsedImplicitly] public sealed partial class PlantAffectGrowth : PlantAdjustAttribute { + public override string GuidebookAttributeName { get; set; } = "plant-attribute-growth"; + public override void Effect(ReagentEffectArgs args) { if (!CanMetabolize(args.SolutionEntity, out var plantHolderComp, args.EntityManager)) diff --git a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantCryoxadone.cs b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantCryoxadone.cs index 83a5f56e59..55a7e5c97b 100644 --- a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantCryoxadone.cs +++ b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantCryoxadone.cs @@ -28,6 +28,6 @@ namespace Content.Server.Chemistry.ReagentEffects.PlantMetabolism plantHolderComp.ForceUpdate = true; } - protected override string? ReagentEffectGuidebookText(IPrototypeManager prototype, IEntitySystemManager entSys) => Loc.GetString("reagent-effect-guidebook-missing", ("chance", Probability)); + protected override string? ReagentEffectGuidebookText(IPrototypeManager prototype, IEntitySystemManager entSys) => Loc.GetString("reagent-effect-guidebook-plant-cryoxadone", ("chance", Probability)); } } diff --git a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantDiethylamine.cs b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantDiethylamine.cs index 23cb436d2f..c98f0be78c 100644 --- a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantDiethylamine.cs +++ b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantDiethylamine.cs @@ -36,6 +36,6 @@ namespace Content.Server.Chemistry.ReagentEffects.PlantMetabolism } } - protected override string? ReagentEffectGuidebookText(IPrototypeManager prototype, IEntitySystemManager entSys) => Loc.GetString("reagent-effect-guidebook-missing", ("chance", Probability)); + protected override string? ReagentEffectGuidebookText(IPrototypeManager prototype, IEntitySystemManager entSys) => Loc.GetString("reagent-effect-guidebook-plant-diethylamine", ("chance", Probability)); } } diff --git a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantPhalanximine.cs b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantPhalanximine.cs index c0640d7fc0..7aaca63b7d 100644 --- a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantPhalanximine.cs +++ b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/PlantPhalanximine.cs @@ -19,6 +19,6 @@ namespace Content.Server.Chemistry.ReagentEffects.PlantMetabolism plantHolderComp.Seed.Viable = true; } - protected override string? ReagentEffectGuidebookText(IPrototypeManager prototype, IEntitySystemManager entSys) => Loc.GetString("reagent-effect-guidebook-missing", ("chance", Probability)); + protected override string? ReagentEffectGuidebookText(IPrototypeManager prototype, IEntitySystemManager entSys) => Loc.GetString("reagent-effect-guidebook-plant-phalanximine", ("chance", Probability)); } } diff --git a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/RobustHarvest.cs b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/RobustHarvest.cs index 990a5a5003..4a01cdf51f 100644 --- a/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/RobustHarvest.cs +++ b/Content.Server/Chemistry/ReagentEffects/PlantMetabolism/RobustHarvest.cs @@ -49,6 +49,6 @@ namespace Content.Server.Chemistry.ReagentEffects.PlantMetabolism } } - protected override string? ReagentEffectGuidebookText(IPrototypeManager prototype, IEntitySystemManager entSys) => Loc.GetString("reagent-effect-guidebook-missing", ("chance", Probability)); + protected override string? ReagentEffectGuidebookText(IPrototypeManager prototype, IEntitySystemManager entSys) => Loc.GetString("reagent-effect-guidebook-plant-robust-harvest", ("seedlesstreshold", PotencySeedlessThreshold), ("limit", PotencyLimit), ("increase", PotencyIncrease), ("chance", Probability)); } } diff --git a/Content.Server/Engineering/EntitySystems/DisassembleOnAltVerbSystem.cs b/Content.Server/Engineering/EntitySystems/DisassembleOnAltVerbSystem.cs index 61b6f3d93d..d694f84a9c 100644 --- a/Content.Server/Engineering/EntitySystems/DisassembleOnAltVerbSystem.cs +++ b/Content.Server/Engineering/EntitySystems/DisassembleOnAltVerbSystem.cs @@ -56,7 +56,7 @@ namespace Content.Server.Engineering.EntitySystems if (component.Deleted || Deleted(uid)) return; - if (!TryComp(uid, out var transformComp)) + if (!TryComp(uid, out TransformComponent? transformComp)) return; var entity = EntityManager.SpawnEntity(component.Prototype, transformComp.Coordinates); diff --git a/Content.Server/Explosion/EntitySystems/TriggerSystem.cs b/Content.Server/Explosion/EntitySystems/TriggerSystem.cs index 8e0a75ea24..7c6b5df7f1 100644 --- a/Content.Server/Explosion/EntitySystems/TriggerSystem.cs +++ b/Content.Server/Explosion/EntitySystems/TriggerSystem.cs @@ -166,7 +166,7 @@ namespace Content.Server.Explosion.EntitySystems private void HandleGibTrigger(EntityUid uid, GibOnTriggerComponent component, TriggerEvent args) { - if (!TryComp(uid, out var xform)) + if (!TryComp(uid, out TransformComponent? xform)) return; if (component.DeleteItems) { diff --git a/Content.Server/Fax/FaxSystem.cs b/Content.Server/Fax/FaxSystem.cs index e86dbca4a1..16d2d391f6 100644 --- a/Content.Server/Fax/FaxSystem.cs +++ b/Content.Server/Fax/FaxSystem.cs @@ -459,7 +459,7 @@ public sealed class FaxSystem : EntitySystem if (sendEntity == null) return; - if (!TryComp(sendEntity, out var metadata) || + if (!TryComp(sendEntity, out MetaDataComponent? metadata) || !TryComp(sendEntity, out var paper)) return; @@ -506,7 +506,7 @@ public sealed class FaxSystem : EntitySystem if (!component.KnownFaxes.TryGetValue(component.DestinationFaxAddress, out var faxName)) return; - if (!TryComp(sendEntity, out var metadata) || + if (!TryComp(sendEntity, out MetaDataComponent? metadata) || !TryComp(sendEntity, out var paper)) return; diff --git a/Content.Server/GameTicking/GameTicker.Spawning.cs b/Content.Server/GameTicking/GameTicker.Spawning.cs index cef570b4a4..9f4b99c312 100644 --- a/Content.Server/GameTicking/GameTicker.Spawning.cs +++ b/Content.Server/GameTicking/GameTicker.Spawning.cs @@ -370,11 +370,16 @@ namespace Content.Server.GameTicking public EntityCoordinates GetObserverSpawnPoint() { _possiblePositions.Clear(); - - foreach (var (point, transform) in EntityManager.EntityQuery(true)) + var spawnPointQuery = EntityManager.EntityQueryEnumerator(); + while (spawnPointQuery.MoveNext(out var uid, out var point, out var transform)) { - if (point.SpawnType != SpawnPointType.Observer) + if (point.SpawnType != SpawnPointType.Observer + || TerminatingOrDeleted(uid) + || transform.MapUid == null + || TerminatingOrDeleted(transform.MapUid.Value)) + { continue; + } _possiblePositions.Add(transform.Coordinates); } @@ -416,7 +421,9 @@ namespace Content.Server.GameTicking if (_mapManager.MapExists(DefaultMap)) { - return new EntityCoordinates(_mapManager.GetMapEntityId(DefaultMap), Vector2.Zero); + var mapUid = _mapManager.GetMapEntityId(DefaultMap); + if (!TerminatingOrDeleted(mapUid)) + return new EntityCoordinates(mapUid, Vector2.Zero); } // Just pick a point at this point I guess. diff --git a/Content.Server/Ghost/GhostSystem.cs b/Content.Server/Ghost/GhostSystem.cs index f4e6a4d607..1a411f13a0 100644 --- a/Content.Server/Ghost/GhostSystem.cs +++ b/Content.Server/Ghost/GhostSystem.cs @@ -306,7 +306,7 @@ namespace Content.Server.Ghost return; } - if (_followerSystem.GetMostFollowed() is not {} target) + if (_followerSystem.GetMostGhostFollowed() is not {} target) return; WarpTo(uid, target); @@ -409,23 +409,41 @@ namespace Content.Server.Ghost return SpawnGhost(mind, spawnPosition, canReturn); } + private bool IsValidSpawnPosition(EntityCoordinates? spawnPosition) + { + if (spawnPosition?.IsValid(EntityManager) != true) + return false; + + var mapUid = spawnPosition?.GetMapUid(EntityManager); + var gridUid = spawnPosition?.EntityId; + // Test if the map is being deleted + if (mapUid == null || TerminatingOrDeleted(mapUid.Value)) + return false; + // Test if the grid is being deleted + if (gridUid != null && TerminatingOrDeleted(gridUid.Value)) + return false; + + return true; + } + public EntityUid? SpawnGhost(Entity mind, EntityCoordinates? spawnPosition = null, bool canReturn = false) { if (!Resolve(mind, ref mind.Comp)) return null; - // Test if the map is being deleted - var mapUid = spawnPosition?.GetMapUid(EntityManager); - if (mapUid == null || TerminatingOrDeleted(mapUid.Value)) + // Test if the map or grid is being deleted + if (!IsValidSpawnPosition(spawnPosition)) spawnPosition = null; + // If it's bad, look for a valid point to spawn spawnPosition ??= _ticker.GetObserverSpawnPoint(); - if (!spawnPosition.Value.IsValid(EntityManager)) + // Make sure the new point is valid too + if (!IsValidSpawnPosition(spawnPosition)) { Log.Warning($"No spawn valid ghost spawn position found for {mind.Comp.CharacterName}" - + " \"{ToPrettyString(mind)}\""); + + $" \"{ToPrettyString(mind)}\""); _minds.TransferTo(mind.Owner, null, createGhost: false, mind: mind.Comp); return null; } diff --git a/Content.Server/Gravity/GravityGeneratorSystem.cs b/Content.Server/Gravity/GravityGeneratorSystem.cs index 8e4da75fac..0b53df63fd 100644 --- a/Content.Server/Gravity/GravityGeneratorSystem.cs +++ b/Content.Server/Gravity/GravityGeneratorSystem.cs @@ -41,7 +41,7 @@ namespace Content.Server.Gravity private void OnComponentShutdown(EntityUid uid, GravityGeneratorComponent component, ComponentShutdown args) { if (component.GravityActive && - TryComp(uid, out var xform) && + TryComp(uid, out TransformComponent? xform) && TryComp(xform.ParentUid, out GravityComponent? gravity)) { component.GravityActive = false; @@ -114,7 +114,7 @@ namespace Content.Server.Gravity UpdateUI(ent, chargeRate); if (active != gravGen.GravityActive && - TryComp(uid, out var xform) && + TryComp(uid, out TransformComponent? xform) && TryComp(xform.ParentUid, out var gravity)) { // Force it on in the faster path. diff --git a/Content.Server/MagicMirror/MagicMirrorSystem.cs b/Content.Server/MagicMirror/MagicMirrorSystem.cs index 84f1f1c3e5..fc1bff9756 100644 --- a/Content.Server/MagicMirror/MagicMirrorSystem.cs +++ b/Content.Server/MagicMirror/MagicMirrorSystem.cs @@ -7,9 +7,7 @@ using Content.Shared.Humanoid; using Content.Shared.Humanoid.Markings; using Content.Shared.Interaction; using Content.Shared.MagicMirror; -using Robust.Server.GameObjects; using Robust.Shared.Audio.Systems; -using Robust.Shared.Player; namespace Content.Server.MagicMirror; @@ -22,14 +20,14 @@ public sealed class MagicMirrorSystem : SharedMagicMirrorSystem [Dependency] private readonly DoAfterSystem _doAfterSystem = default!; [Dependency] private readonly MarkingManager _markings = default!; [Dependency] private readonly HumanoidAppearanceSystem _humanoid = default!; - [Dependency] private readonly UserInterfaceSystem _uiSystem = default!; public override void Initialize() { base.Initialize(); SubscribeLocalEvent(OnOpenUIAttempt); - Subs.BuiEvents(MagicMirrorUiKey.Key, subs => + Subs.BuiEvents(MagicMirrorUiKey.Key, + subs => { subs.Event(OnUiClosed); subs.Event(OnMagicMirrorSelect); @@ -278,32 +276,6 @@ public sealed class MagicMirrorSystem : SharedMagicMirrorSystem } - private void UpdateInterface(EntityUid mirrorUid, EntityUid targetUid, MagicMirrorComponent component) - { - if (!TryComp(targetUid, out var humanoid)) - return; - - var hair = humanoid.MarkingSet.TryGetCategory(MarkingCategories.Hair, out var hairMarkings) - ? new List(hairMarkings) - : new(); - - var facialHair = humanoid.MarkingSet.TryGetCategory(MarkingCategories.FacialHair, out var facialHairMarkings) - ? new List(facialHairMarkings) - : new(); - - var state = new MagicMirrorUiState( - humanoid.Species, - hair, - humanoid.MarkingSet.PointsLeft(MarkingCategories.Hair) + hair.Count, - facialHair, - humanoid.MarkingSet.PointsLeft(MarkingCategories.FacialHair) + facialHair.Count); - - // TODO: Component states - component.Target = targetUid; - _uiSystem.SetUiState(mirrorUid, MagicMirrorUiKey.Key, state); - Dirty(mirrorUid, component); - } - private void OnUiClosed(Entity ent, ref BoundUIClosedEvent args) { ent.Comp.Target = null; diff --git a/Content.Server/Medical/DefibrillatorSystem.cs b/Content.Server/Medical/DefibrillatorSystem.cs index 64861fdc51..4373532f01 100644 --- a/Content.Server/Medical/DefibrillatorSystem.cs +++ b/Content.Server/Medical/DefibrillatorSystem.cs @@ -162,6 +162,9 @@ public sealed class DefibrillatorSystem : EntitySystem if (_mobState.IsAlive(target, mobState)) return false; + if (!component.CanDefibCrit && _mobState.IsCritical(target, mobState)) + return false; + return true; } @@ -179,7 +182,8 @@ public sealed class DefibrillatorSystem : EntitySystem { BlockDuplicate = true, BreakOnHandChange = true, - NeedHand = true + NeedHand = true, + BreakOnMove = !component.AllowDoAfterMovement }); } @@ -254,6 +258,10 @@ public sealed class DefibrillatorSystem : EntitySystem // if we don't have enough power left for another shot, turn it off if (!_powerCell.HasActivatableCharge(uid)) TryDisable(uid, component); + + // TODO clean up this clown show above + var ev = new TargetDefibrillatedEvent(user, (uid, component)); + RaiseLocalEvent(target, ref ev); } public override void Update(float frameTime) diff --git a/Content.Server/Medical/MedicalScannerSystem.cs b/Content.Server/Medical/MedicalScannerSystem.cs index 91184ddc16..b24690e204 100644 --- a/Content.Server/Medical/MedicalScannerSystem.cs +++ b/Content.Server/Medical/MedicalScannerSystem.cs @@ -86,7 +86,7 @@ namespace Content.Server.Medical return; var name = "Unknown"; - if (TryComp(args.Using.Value, out var metadata)) + if (TryComp(args.Using.Value, out MetaDataComponent? metadata)) name = metadata.EntityName; InteractionVerb verb = new() diff --git a/Content.Server/NPC/Pathfinding/PathfindingSystem.Distance.cs b/Content.Server/NPC/Pathfinding/PathfindingSystem.Distance.cs index 95d5c9c465..5daf38c420 100644 --- a/Content.Server/NPC/Pathfinding/PathfindingSystem.Distance.cs +++ b/Content.Server/NPC/Pathfinding/PathfindingSystem.Distance.cs @@ -30,8 +30,8 @@ public sealed partial class PathfindingSystem if (end.GraphUid != start.GraphUid) { - if (!TryComp(start.GraphUid, out var startXform) || - !TryComp(end.GraphUid, out var endXform)) + if (!TryComp(start.GraphUid, out TransformComponent? startXform) || + !TryComp(end.GraphUid, out TransformComponent? endXform)) { return Vector2.Zero; } diff --git a/Content.Server/NPC/Pathfinding/PathfindingSystem.Grid.cs b/Content.Server/NPC/Pathfinding/PathfindingSystem.Grid.cs index 6462c10fe5..52f7db77ed 100644 --- a/Content.Server/NPC/Pathfinding/PathfindingSystem.Grid.cs +++ b/Content.Server/NPC/Pathfinding/PathfindingSystem.Grid.cs @@ -261,7 +261,7 @@ public sealed partial class PathfindingSystem private void OnBodyTypeChange(ref PhysicsBodyTypeChangedEvent ev) { - if (TryComp(ev.Entity, out var xform) && + if (TryComp(ev.Entity, out TransformComponent? xform) && xform.GridUid != null) { var aabb = _lookup.GetAABBNoContainer(ev.Entity, xform.Coordinates.Position, xform.LocalRotation); diff --git a/Content.Server/NPC/Pathfinding/PathfindingSystem.cs b/Content.Server/NPC/Pathfinding/PathfindingSystem.cs index a59af88ff5..3672ad047b 100644 --- a/Content.Server/NPC/Pathfinding/PathfindingSystem.cs +++ b/Content.Server/NPC/Pathfinding/PathfindingSystem.cs @@ -264,7 +264,7 @@ namespace Content.Server.NPC.Pathfinding int limit = 40, PathFlags flags = PathFlags.None) { - if (!TryComp(entity, out var start)) + if (!TryComp(entity, out TransformComponent? start)) return new PathResultEvent(PathResult.NoPath, new List()); var layer = 0; @@ -294,7 +294,7 @@ namespace Content.Server.NPC.Pathfinding CancellationToken cancelToken, PathFlags flags = PathFlags.None) { - if (!TryComp(entity, out var start)) + if (!TryComp(entity, out TransformComponent? start)) return null; var request = GetRequest(entity, start.Coordinates, end, range, cancelToken, flags); @@ -325,8 +325,8 @@ namespace Content.Server.NPC.Pathfinding CancellationToken cancelToken, PathFlags flags = PathFlags.None) { - if (!TryComp(entity, out var xform) || - !TryComp(target, out var targetXform)) + if (!TryComp(entity, out TransformComponent? xform) || + !TryComp(target, out TransformComponent? targetXform)) return new PathResultEvent(PathResult.NoPath, new List()); var request = GetRequest(entity, xform.Coordinates, targetXform.Coordinates, range, cancelToken, flags); @@ -400,7 +400,7 @@ namespace Content.Server.NPC.Pathfinding var gridUid = coordinates.GetGridUid(EntityManager); if (!TryComp(gridUid, out var comp) || - !TryComp(gridUid, out var xform)) + !TryComp(gridUid, out TransformComponent? xform)) { return null; } diff --git a/Content.Server/NPC/Systems/NPCUtilitySystem.cs b/Content.Server/NPC/Systems/NPCUtilitySystem.cs index 4b0ccafa1d..2e8c628b50 100644 --- a/Content.Server/NPC/Systems/NPCUtilitySystem.cs +++ b/Content.Server/NPC/Systems/NPCUtilitySystem.cs @@ -260,8 +260,8 @@ public sealed class NPCUtilitySystem : EntitySystem { var radius = blackboard.GetValueOrDefault(NPCBlackboard.VisionRadius, EntityManager); - if (!TryComp(targetUid, out var targetXform) || - !TryComp(owner, out var xform)) + if (!TryComp(targetUid, out TransformComponent? targetXform) || + !TryComp(owner, out TransformComponent? xform)) { return 0f; } @@ -308,8 +308,8 @@ public sealed class NPCUtilitySystem : EntitySystem if (blackboard.TryGetValue("Target", out var currentTarget, EntityManager) && currentTarget == targetUid && - TryComp(owner, out var xform) && - TryComp(targetUid, out var targetXform) && + TryComp(owner, out TransformComponent? xform) && + TryComp(targetUid, out TransformComponent? targetXform) && xform.Coordinates.TryDistance(EntityManager, _transform, targetXform.Coordinates, out var distance) && distance <= radius + bufferRange) { diff --git a/Content.Server/PAI/PAISystem.cs b/Content.Server/PAI/PAISystem.cs index 091afb1557..0cdb0bc29a 100644 --- a/Content.Server/PAI/PAISystem.cs +++ b/Content.Server/PAI/PAISystem.cs @@ -111,7 +111,7 @@ public sealed class PAISystem : SharedPAISystem if (TryComp(uid, out var instrument)) _instrumentSystem.Clean(uid, instrument); - if (TryComp(uid, out var metadata)) + if (TryComp(uid, out MetaDataComponent? metadata)) { var proto = metadata.EntityPrototype; if (proto != null) diff --git a/Content.Server/Paper/PaperSystem.cs b/Content.Server/Paper/PaperSystem.cs index d10d04cfb9..4a7828c78c 100644 --- a/Content.Server/Paper/PaperSystem.cs +++ b/Content.Server/Paper/PaperSystem.cs @@ -148,7 +148,7 @@ namespace Content.Server.Paper if (TryComp(uid, out var appearance)) _appearance.SetData(uid, PaperVisuals.Status, PaperStatus.Written, appearance); - if (TryComp(uid, out var meta)) + if (TryComp(uid, out MetaDataComponent? meta)) _metaSystem.SetEntityDescription(uid, "", meta); _adminLogger.Add(LogType.Chat, LogImpact.Low, diff --git a/Content.Server/Physics/Controllers/MoverController.cs b/Content.Server/Physics/Controllers/MoverController.cs index 759b8ef29c..6edc202d15 100644 --- a/Content.Server/Physics/Controllers/MoverController.cs +++ b/Content.Server/Physics/Controllers/MoverController.cs @@ -271,7 +271,7 @@ namespace Content.Server.Physics.Controllers consoleEnt = cargoConsole.Entity; } - if (!TryComp(consoleEnt, out var xform)) continue; + if (!TryComp(consoleEnt, out TransformComponent? xform)) continue; var gridId = xform.GridUid; // This tries to see if the grid is a shuttle and if the console should work. diff --git a/Content.Server/Pointing/EntitySystems/PointingSystem.cs b/Content.Server/Pointing/EntitySystems/PointingSystem.cs index 7bbf6409cd..960c8dc28a 100644 --- a/Content.Server/Pointing/EntitySystems/PointingSystem.cs +++ b/Content.Server/Pointing/EntitySystems/PointingSystem.cs @@ -88,7 +88,10 @@ namespace Content.Server.Pointing.EntitySystems ? viewerPointedAtMessage : viewerMessage; - RaiseNetworkEvent(new PopupEntityEvent(message, PopupType.Small, netSource), viewerEntity); + // Someone pointing at YOU is slightly more important + var popupType = viewerEntity == pointed ? PopupType.Medium : PopupType.Small; + + RaiseNetworkEvent(new PopupEntityEvent(message, popupType, netSource), viewerEntity); } _replay.RecordServerMessage(new PopupEntityEvent(viewerMessage, PopupType.Small, netSource)); diff --git a/Content.Server/Polymorph/Systems/PolymorphSystem.cs b/Content.Server/Polymorph/Systems/PolymorphSystem.cs index e6ba1d02af..d4a9159d44 100644 --- a/Content.Server/Polymorph/Systems/PolymorphSystem.cs +++ b/Content.Server/Polymorph/Systems/PolymorphSystem.cs @@ -248,7 +248,7 @@ public sealed partial class PolymorphSystem : EntitySystem } } - if (configuration.TransferName && TryComp(uid, out var targetMeta)) + if (configuration.TransferName && TryComp(uid, out MetaDataComponent? targetMeta)) _metaData.SetEntityName(child, targetMeta.EntityName); if (configuration.TransferHumanoidAppearance) diff --git a/Content.Server/Projectiles/ProjectileSystem.cs b/Content.Server/Projectiles/ProjectileSystem.cs index 0061b16e47..f8c8ef64b7 100644 --- a/Content.Server/Projectiles/ProjectileSystem.cs +++ b/Content.Server/Projectiles/ProjectileSystem.cs @@ -72,7 +72,7 @@ public sealed class ProjectileSystem : SharedProjectileSystem if (component.DeleteOnCollide) QueueDel(uid); - if (component.ImpactEffect != null && TryComp(uid, out var xform)) + if (component.ImpactEffect != null && TryComp(uid, out TransformComponent? xform)) { RaiseNetworkEvent(new ImpactEffectEvent(component.ImpactEffect, GetNetCoordinates(xform.Coordinates)), Filter.Pvs(xform.Coordinates, entityMan: EntityManager)); } diff --git a/Content.Server/Salvage/FultonSystem.cs b/Content.Server/Salvage/FultonSystem.cs index a24bab4584..ad998e5359 100644 --- a/Content.Server/Salvage/FultonSystem.cs +++ b/Content.Server/Salvage/FultonSystem.cs @@ -53,7 +53,7 @@ public sealed class FultonSystem : SharedFultonSystem private void Fulton(EntityUid uid, FultonedComponent component) { if (!Deleted(component.Beacon) && - TryComp(component.Beacon, out var beaconXform) && + TryComp(component.Beacon, out TransformComponent? beaconXform) && !Container.IsEntityOrParentInContainer(component.Beacon.Value, xform: beaconXform) && CanFulton(uid)) { diff --git a/Content.Server/Salvage/SalvageSystem.Runner.cs b/Content.Server/Salvage/SalvageSystem.Runner.cs index 23607e2bdc..161b791084 100644 --- a/Content.Server/Salvage/SalvageSystem.Runner.cs +++ b/Content.Server/Salvage/SalvageSystem.Runner.cs @@ -32,7 +32,7 @@ public sealed partial class SalvageSystem private void OnConsoleFTLAttempt(ref ConsoleFTLAttemptEvent ev) { - if (!TryComp(ev.Uid, out var xform) || + if (!TryComp(ev.Uid, out TransformComponent? xform) || !TryComp(xform.MapUid, out var salvage)) { return; diff --git a/Content.Server/Shuttles/Systems/ArrivalsSystem.cs b/Content.Server/Shuttles/Systems/ArrivalsSystem.cs index 23f7e10a3e..e87e781e62 100644 --- a/Content.Server/Shuttles/Systems/ArrivalsSystem.cs +++ b/Content.Server/Shuttles/Systems/ArrivalsSystem.cs @@ -316,7 +316,7 @@ public sealed class ArrivalsSystem : EntitySystem TryGetArrivals(out var arrivals); - if (TryComp(arrivals, out var arrivalsXform)) + if (TryComp(arrivals, out TransformComponent? arrivalsXform)) { var mapId = arrivalsXform.MapID; @@ -413,7 +413,7 @@ public sealed class ArrivalsSystem : EntitySystem var curTime = _timing.CurTime; TryGetArrivals(out var arrivals); - if (TryComp(arrivals, out var arrivalsXform)) + if (TryComp(arrivals, out TransformComponent? arrivalsXform)) { while (query.MoveNext(out var uid, out var comp, out var shuttle, out var xform)) { diff --git a/Content.Server/Shuttles/Systems/EmergencyShuttleSystem.cs b/Content.Server/Shuttles/Systems/EmergencyShuttleSystem.cs index 9bfe1bf986..2d8ae4b735 100644 --- a/Content.Server/Shuttles/Systems/EmergencyShuttleSystem.cs +++ b/Content.Server/Shuttles/Systems/EmergencyShuttleSystem.cs @@ -261,7 +261,7 @@ public sealed partial class EmergencyShuttleSystem : EntitySystem if (!Resolve(stationUid, ref stationShuttle)) return; - if (!TryComp(stationShuttle.EmergencyShuttle, out var xform) || + if (!TryComp(stationShuttle.EmergencyShuttle, out TransformComponent? xform) || !TryComp(stationShuttle.EmergencyShuttle, out var shuttle)) { Log.Error($"Attempted to call an emergency shuttle for an uninitialized station? Station: {ToPrettyString(stationUid)}. Shuttle: {ToPrettyString(stationShuttle.EmergencyShuttle)}"); @@ -284,7 +284,7 @@ public sealed partial class EmergencyShuttleSystem : EntitySystem if (_shuttle.TryFTLDock(stationShuttle.EmergencyShuttle.Value, shuttle, targetGrid.Value, DockTag)) { - if (TryComp(targetGrid.Value, out var targetXform)) + if (TryComp(targetGrid.Value, out TransformComponent? targetXform)) { var angle = _dock.GetAngle(stationShuttle.EmergencyShuttle.Value, xform, targetGrid.Value, targetXform, xformQuery); _chatSystem.DispatchStationAnnouncement(stationUid, Loc.GetString("emergency-shuttle-docked", ("time", $"{_consoleAccumulator:0}"), ("direction", angle.GetDir())), playDefaultSound: false); @@ -330,7 +330,7 @@ public sealed partial class EmergencyShuttleSystem : EntitySystem return; // Post mapinit? fancy - if (TryComp(component.Entity, out var xform)) + if (TryComp(component.Entity, out TransformComponent? xform)) { component.MapEntity = xform.MapUid; return; diff --git a/Content.Server/Shuttles/Systems/ShuttleConsoleSystem.cs b/Content.Server/Shuttles/Systems/ShuttleConsoleSystem.cs index 89dc114caf..2b5769881d 100644 --- a/Content.Server/Shuttles/Systems/ShuttleConsoleSystem.cs +++ b/Content.Server/Shuttles/Systems/ShuttleConsoleSystem.cs @@ -242,7 +242,7 @@ public sealed partial class ShuttleConsoleSystem : SharedShuttleConsoleSystem RaiseLocalEvent(entity.Value, ref getShuttleEv); entity = getShuttleEv.Console; - TryComp(entity, out var consoleXform); + TryComp(entity, out TransformComponent? consoleXform); var shuttleGridUid = consoleXform?.GridUid; NavInterfaceState navState; diff --git a/Content.Server/Shuttles/Systems/ShuttleSystem.GridFill.cs b/Content.Server/Shuttles/Systems/ShuttleSystem.GridFill.cs index c4cf2820e2..853548add3 100644 --- a/Content.Server/Shuttles/Systems/ShuttleSystem.GridFill.cs +++ b/Content.Server/Shuttles/Systems/ShuttleSystem.GridFill.cs @@ -184,7 +184,7 @@ public sealed partial class ShuttleSystem return; if (!TryComp(uid, out var dock) || - !TryComp(uid, out var xform) || + !TryComp(uid, out TransformComponent? xform) || xform.GridUid == null) { return; @@ -196,7 +196,7 @@ public sealed partial class ShuttleSystem if (_loader.TryLoad(mapId, component.Path.ToString(), out var ent) && ent.Count == 1 && - TryComp(ent[0], out var shuttleXform)) + TryComp(ent[0], out TransformComponent? shuttleXform)) { var escape = GetSingleDock(ent[0]); diff --git a/Content.Server/Shuttles/Systems/ShuttleSystem.IFF.cs b/Content.Server/Shuttles/Systems/ShuttleSystem.IFF.cs index ce79466b58..ed5d109e85 100644 --- a/Content.Server/Shuttles/Systems/ShuttleSystem.IFF.cs +++ b/Content.Server/Shuttles/Systems/ShuttleSystem.IFF.cs @@ -16,7 +16,7 @@ public sealed partial class ShuttleSystem private void OnIFFShow(EntityUid uid, IFFConsoleComponent component, IFFShowIFFMessage args) { - if (!TryComp(uid, out var xform) || xform.GridUid == null || + if (!TryComp(uid, out TransformComponent? xform) || xform.GridUid == null || (component.AllowedFlags & IFFFlags.HideLabel) == 0x0) { return; @@ -34,7 +34,7 @@ public sealed partial class ShuttleSystem private void OnIFFShowVessel(EntityUid uid, IFFConsoleComponent component, IFFShowVesselMessage args) { - if (!TryComp(uid, out var xform) || xform.GridUid == null || + if (!TryComp(uid, out TransformComponent? xform) || xform.GridUid == null || (component.AllowedFlags & IFFFlags.Hide) == 0x0) { return; @@ -54,7 +54,7 @@ public sealed partial class ShuttleSystem { // If we anchor / re-anchor then make sure flags up to date. if (!args.Anchored || - !TryComp(uid, out var xform) || + !TryComp(uid, out TransformComponent? xform) || !TryComp(xform.GridUid, out var iff)) { _uiSystem.SetUiState(uid, IFFConsoleUiKey.Key, new IFFConsoleBoundUserInterfaceState() diff --git a/Content.Server/Spawners/EntitySystems/SpawnOnDespawnSystem.cs b/Content.Server/Spawners/EntitySystems/SpawnOnDespawnSystem.cs index 77927c9bba..f5a34728dc 100644 --- a/Content.Server/Spawners/EntitySystems/SpawnOnDespawnSystem.cs +++ b/Content.Server/Spawners/EntitySystems/SpawnOnDespawnSystem.cs @@ -14,7 +14,7 @@ public sealed class SpawnOnDespawnSystem : EntitySystem private void OnDespawn(EntityUid uid, SpawnOnDespawnComponent comp, ref TimedDespawnEvent args) { - if (!TryComp(uid, out var xform)) + if (!TryComp(uid, out TransformComponent? xform)) return; Spawn(comp.Prototype, xform.Coordinates); diff --git a/Content.Shared/Chemistry/Reagent/ReagentPrototype.cs b/Content.Shared/Chemistry/Reagent/ReagentPrototype.cs index 6095676b9e..7e96332ebe 100644 --- a/Content.Shared/Chemistry/Reagent/ReagentPrototype.cs +++ b/Content.Shared/Chemistry/Reagent/ReagentPrototype.cs @@ -195,12 +195,22 @@ namespace Content.Shared.Chemistry.Reagent public Dictionary, ReagentEffectsGuideEntry>? GuideEntries; + public List? PlantMetabolisms = null; + public ReagentGuideEntry(ReagentPrototype proto, IPrototypeManager prototype, IEntitySystemManager entSys) { ReagentPrototype = proto.ID; GuideEntries = proto.Metabolisms? .Select(x => (x.Key, x.Value.MakeGuideEntry(prototype, entSys))) .ToDictionary(x => x.Key, x => x.Item2); + if (proto.PlantMetabolisms.Count > 0) + { + PlantMetabolisms = new List (proto.PlantMetabolisms + .Select(x => x.GuidebookEffectDescription(prototype, entSys)) + .Where(x => x is not null) + .Select(x => x!) + .ToArray()); + } } } diff --git a/Content.Shared/Follower/FollowerSystem.cs b/Content.Shared/Follower/FollowerSystem.cs index 6c02b13076..8027ee449c 100644 --- a/Content.Shared/Follower/FollowerSystem.cs +++ b/Content.Shared/Follower/FollowerSystem.cs @@ -1,11 +1,11 @@ using System.Numerics; +using Content.Shared.Administration.Managers; using Content.Shared.Database; using Content.Shared.Follower.Components; using Content.Shared.Ghost; using Content.Shared.Hands; using Content.Shared.Movement.Events; using Content.Shared.Movement.Pulling.Events; -using Content.Shared.Movement.Systems; using Content.Shared.Tag; using Content.Shared.Verbs; using Robust.Shared.Containers; @@ -14,6 +14,7 @@ using Robust.Shared.Map.Events; using Robust.Shared.Network; using Robust.Shared.Physics; using Robust.Shared.Physics.Systems; +using Robust.Shared.Player; using Robust.Shared.Utility; namespace Content.Shared.Follower; @@ -26,6 +27,7 @@ public sealed class FollowerSystem : EntitySystem [Dependency] private readonly SharedJointSystem _jointSystem = default!; [Dependency] private readonly SharedPhysicsSystem _physicsSystem = default!; [Dependency] private readonly INetManager _netMan = default!; + [Dependency] private readonly ISharedAdminManager _adminManager = default!; public override void Initialize() { @@ -249,20 +251,33 @@ public sealed class FollowerSystem : EntitySystem } /// - /// Get the most followed entity. + /// Gets the entity with the most non-admin ghosts following it. /// - public EntityUid? GetMostFollowed() + public EntityUid? GetMostGhostFollowed() { EntityUid? picked = null; - int most = 0; - var query = EntityQueryEnumerator(); - while (query.MoveNext(out var uid, out var comp)) + var most = 0; + + // Keep a tally of how many ghosts are following each entity + var followedEnts = new Dictionary(); + + // Look for followers that are ghosts and are player controlled + var query = EntityQueryEnumerator(); + while (query.MoveNext(out _, out var follower, out _, out var actor)) { - var count = comp.Following.Count; - if (count > most) + // Exclude admins + if (_adminManager.IsAdmin(actor.PlayerSession)) + continue; + + var followed = follower.Following; + // Add new entry or increment existing + followedEnts.TryGetValue(followed, out var currentValue); + followedEnts[followed] = currentValue + 1; + + if (followedEnts[followed] > most) { - picked = uid; - most = count; + picked = followed; + most = followedEnts[followed]; } } diff --git a/Content.Shared/Interaction/SharedInteractionSystem.cs b/Content.Shared/Interaction/SharedInteractionSystem.cs index 8b3431cb02..c82a749755 100644 --- a/Content.Shared/Interaction/SharedInteractionSystem.cs +++ b/Content.Shared/Interaction/SharedInteractionSystem.cs @@ -570,7 +570,7 @@ namespace Content.Shared.Interaction Ignored? predicate = null, bool popup = false) { - if (!TryComp(other, out var otherXform)) + if (!TryComp(other, out TransformComponent? otherXform)) return false; return InRangeUnobstructed(origin, other, otherXform.Coordinates, otherXform.LocalRotation, range, collisionMask, predicate, @@ -633,7 +633,7 @@ namespace Content.Shared.Interaction fixtureA.FixtureCount > 0 && TryComp(other, out var fixtureB) && fixtureB.FixtureCount > 0 && - TryComp(origin, out var xformA)) + TryComp(origin, out TransformComponent? xformA)) { var (worldPosA, worldRotA) = xformA.GetWorldPositionRotation(); var xfA = new Transform(worldPosA, worldRotA); diff --git a/Content.Shared/MagicMirror/MagicMirrorComponent.cs b/Content.Shared/MagicMirror/MagicMirrorComponent.cs index 6357543905..95b1736979 100644 --- a/Content.Shared/MagicMirror/MagicMirrorComponent.cs +++ b/Content.Shared/MagicMirror/MagicMirrorComponent.cs @@ -47,5 +47,5 @@ public sealed partial class MagicMirrorComponent : Component /// Sound emitted when slots are changed /// [DataField, ViewVariables(VVAccess.ReadWrite)] - public SoundSpecifier ChangeHairSound = new SoundPathSpecifier("/Audio/Items/scissors.ogg"); + public SoundSpecifier? ChangeHairSound = new SoundPathSpecifier("/Audio/Items/scissors.ogg"); } diff --git a/Content.Shared/MagicMirror/SharedMagicMirrorSystem.cs b/Content.Shared/MagicMirror/SharedMagicMirrorSystem.cs index f9c941ffe3..91059d60bf 100644 --- a/Content.Shared/MagicMirror/SharedMagicMirrorSystem.cs +++ b/Content.Shared/MagicMirror/SharedMagicMirrorSystem.cs @@ -1,6 +1,8 @@ using Content.Shared.DoAfter; +using Content.Shared.Humanoid; using Content.Shared.Humanoid.Markings; using Content.Shared.Interaction; +using Content.Shared.UserInterface; using Robust.Shared.Serialization; namespace Content.Shared.MagicMirror; @@ -8,10 +10,12 @@ namespace Content.Shared.MagicMirror; public abstract class SharedMagicMirrorSystem : EntitySystem { [Dependency] private readonly SharedInteractionSystem _interaction = default!; + [Dependency] protected readonly SharedUserInterfaceSystem _uiSystem = default!; public override void Initialize() { base.Initialize(); + SubscribeLocalEvent(OnBeforeUIOpen); SubscribeLocalEvent(OnMirrorRangeCheck); } @@ -22,6 +26,38 @@ public abstract class SharedMagicMirrorSystem : EntitySystem args.Result = BoundUserInterfaceRangeResult.Fail; } } + + private void OnBeforeUIOpen(Entity ent, ref BeforeActivatableUIOpenEvent args) + { + ent.Comp.Target ??= args.User; + UpdateInterface(ent, args.User, ent); + } + + protected void UpdateInterface(EntityUid mirrorUid, EntityUid targetUid, MagicMirrorComponent component) + { + if (!TryComp(targetUid, out var humanoid)) + return; + + var hair = humanoid.MarkingSet.TryGetCategory(MarkingCategories.Hair, out var hairMarkings) + ? new List(hairMarkings) + : new(); + + var facialHair = humanoid.MarkingSet.TryGetCategory(MarkingCategories.FacialHair, out var facialHairMarkings) + ? new List(facialHairMarkings) + : new(); + + var state = new MagicMirrorUiState( + humanoid.Species, + hair, + humanoid.MarkingSet.PointsLeft(MarkingCategories.Hair) + hair.Count, + facialHair, + humanoid.MarkingSet.PointsLeft(MarkingCategories.FacialHair) + facialHair.Count); + + // TODO: Component states + component.Target = targetUid; + _uiSystem.SetUiState(mirrorUid, MagicMirrorUiKey.Key, state); + Dirty(mirrorUid, component); + } } [Serializable, NetSerializable] diff --git a/Content.Shared/Medical/DefibrillatorComponent.cs b/Content.Shared/Medical/DefibrillatorComponent.cs index 2da5285285..61a02187d0 100644 --- a/Content.Shared/Medical/DefibrillatorComponent.cs +++ b/Content.Shared/Medical/DefibrillatorComponent.cs @@ -60,6 +60,12 @@ public sealed partial class DefibrillatorComponent : Component [DataField("doAfterDuration"), ViewVariables(VVAccess.ReadWrite)] public TimeSpan DoAfterDuration = TimeSpan.FromSeconds(3); + [DataField] + public bool AllowDoAfterMovement = true; + + [DataField] + public bool CanDefibCrit = true; + /// /// The sound when someone is zapped. /// diff --git a/Content.Shared/Medical/TargetDefibrillatedEvent.cs b/Content.Shared/Medical/TargetDefibrillatedEvent.cs new file mode 100644 index 0000000000..60d1a21584 --- /dev/null +++ b/Content.Shared/Medical/TargetDefibrillatedEvent.cs @@ -0,0 +1,4 @@ +namespace Content.Shared.Medical; + +[ByRefEvent] +public readonly record struct TargetDefibrillatedEvent(EntityUid User, Entity Defibrillator); diff --git a/Content.Shared/Movement/Systems/SharedJetpackSystem.cs b/Content.Shared/Movement/Systems/SharedJetpackSystem.cs index 8c42511f84..724eca682f 100644 --- a/Content.Shared/Movement/Systems/SharedJetpackSystem.cs +++ b/Content.Shared/Movement/Systems/SharedJetpackSystem.cs @@ -113,7 +113,7 @@ public abstract class SharedJetpackSystem : EntitySystem if (args.Handled) return; - if (TryComp(uid, out var xform) && !CanEnableOnGrid(xform.GridUid)) + if (TryComp(uid, out TransformComponent? xform) && !CanEnableOnGrid(xform.GridUid)) { _popup.PopupClient(Loc.GetString("jetpack-no-station"), uid, args.Performer); diff --git a/Content.Shared/Movement/Systems/SharedMoverController.Input.cs b/Content.Shared/Movement/Systems/SharedMoverController.Input.cs index ba175b345f..1ccb7f0c3f 100644 --- a/Content.Shared/Movement/Systems/SharedMoverController.Input.cs +++ b/Content.Shared/Movement/Systems/SharedMoverController.Input.cs @@ -313,7 +313,7 @@ namespace Content.Shared.Movement.Systems // For stuff like "Moving out of locker" or the likes // We'll relay a movement input to the parent. if (_container.IsEntityInContainer(entity) && - TryComp(entity, out var xform) && + TryComp(entity, out TransformComponent? xform) && xform.ParentUid.IsValid() && _mobState.IsAlive(entity)) { diff --git a/Content.Shared/Nutrition/EntitySystems/PressurizedSolutionSystem.cs b/Content.Shared/Nutrition/EntitySystems/PressurizedSolutionSystem.cs index d63b8e7326..82d90f4c92 100644 --- a/Content.Shared/Nutrition/EntitySystems/PressurizedSolutionSystem.cs +++ b/Content.Shared/Nutrition/EntitySystems/PressurizedSolutionSystem.cs @@ -179,7 +179,7 @@ public sealed partial class PressurizedSolutionSystem : EntitySystem var solution = _solutionContainer.SplitSolution(soln.Value, interactions.Volume); // Spray the solution onto the ground and anyone nearby - if (TryComp(entity, out var transform)) + if (TryComp(entity, out TransformComponent? transform)) _puddle.TrySplashSpillAt(entity, transform.Coordinates, solution, out _, sound: false); var drinkName = Identity.Entity(entity, EntityManager); diff --git a/Content.Shared/Nutrition/EntitySystems/SharedDrinkSystem.cs b/Content.Shared/Nutrition/EntitySystems/SharedDrinkSystem.cs index 7cae3b9208..bf1e585fab 100644 --- a/Content.Shared/Nutrition/EntitySystems/SharedDrinkSystem.cs +++ b/Content.Shared/Nutrition/EntitySystems/SharedDrinkSystem.cs @@ -81,7 +81,7 @@ public abstract partial class SharedDrinkSystem : EntitySystem { string remainingString = "drink-component-on-examine-is-half-full"; - if (TryComp(args.Examiner, out var examiner) && examiner.EntityName.Length > 0 + if (TryComp(args.Examiner, out MetaDataComponent? examiner) && examiner.EntityName.Length > 0 && string.Compare(examiner.EntityName.Substring(0, 1), "m", StringComparison.InvariantCultureIgnoreCase) > 0) remainingString = "drink-component-on-examine-is-half-empty"; diff --git a/Content.Shared/Random/RulesSystem.cs b/Content.Shared/Random/RulesSystem.cs index f8711fb63e..6b8a58abb7 100644 --- a/Content.Shared/Random/RulesSystem.cs +++ b/Content.Shared/Random/RulesSystem.cs @@ -26,7 +26,7 @@ public sealed class RulesSystem : EntitySystem break; case GridInRangeRule griddy: { - if (!TryComp(uid, out var xform)) + if (!TryComp(uid, out TransformComponent? xform)) { return false; } @@ -50,7 +50,7 @@ public sealed class RulesSystem : EntitySystem } case InSpaceRule: { - if (!TryComp(uid, out var xform) || + if (!TryComp(uid, out TransformComponent? xform) || xform.GridUid != null) { return false; @@ -146,7 +146,7 @@ public sealed class RulesSystem : EntitySystem } case NearbyEntitiesRule entity: { - if (!TryComp(uid, out var xform) || + if (!TryComp(uid, out TransformComponent? xform) || xform.MapUid == null) { return false; @@ -177,7 +177,7 @@ public sealed class RulesSystem : EntitySystem } case NearbyTilesPercentRule tiles: { - if (!TryComp(uid, out var xform) || + if (!TryComp(uid, out TransformComponent? xform) || !TryComp(xform.GridUid, out var grid)) { return false; @@ -227,7 +227,7 @@ public sealed class RulesSystem : EntitySystem } case OnMapGridRule: { - if (!TryComp(uid, out var xform) || + if (!TryComp(uid, out TransformComponent? xform) || xform.GridUid != xform.MapUid || xform.MapUid == null) { diff --git a/Content.Shared/Sound/SharedEmitSoundSystem.cs b/Content.Shared/Sound/SharedEmitSoundSystem.cs index a9a50698d7..0dcdc44c9f 100644 --- a/Content.Shared/Sound/SharedEmitSoundSystem.cs +++ b/Content.Shared/Sound/SharedEmitSoundSystem.cs @@ -72,7 +72,7 @@ public abstract class SharedEmitSoundSystem : EntitySystem private void OnEmitSoundOnLand(EntityUid uid, BaseEmitSoundComponent component, ref LandEvent args) { if (!args.PlaySound || - !TryComp(uid, out var xform) || + !TryComp(uid, out TransformComponent? xform) || !TryComp(xform.GridUid, out var grid)) { return; diff --git a/Content.Shared/Standing/StandingStateComponent.cs b/Content.Shared/Standing/StandingStateComponent.cs index 5d7bb0a59f..0270872235 100644 --- a/Content.Shared/Standing/StandingStateComponent.cs +++ b/Content.Shared/Standing/StandingStateComponent.cs @@ -9,7 +9,7 @@ namespace Content.Shared.Standing { [ViewVariables(VVAccess.ReadWrite)] [DataField] - public SoundSpecifier DownSound { get; private set; } = new SoundCollectionSpecifier("BodyFall"); + public SoundSpecifier? DownSound { get; private set; } = new SoundCollectionSpecifier("BodyFall"); [DataField, AutoNetworkedField] public bool Standing { get; set; } = true; diff --git a/Content.Shared/Storage/EntitySystems/SharedStorageSystem.cs b/Content.Shared/Storage/EntitySystems/SharedStorageSystem.cs index 71883cde25..a55f21f2e2 100644 --- a/Content.Shared/Storage/EntitySystems/SharedStorageSystem.cs +++ b/Content.Shared/Storage/EntitySystems/SharedStorageSystem.cs @@ -468,7 +468,7 @@ public abstract class SharedStorageSystem : EntitySystem return; } - if (_xformQuery.TryGetComponent(uid, out var transformOwner) && TryComp(target, out var transformEnt)) + if (TryComp(uid, out TransformComponent? transformOwner) && TryComp(target, out TransformComponent? transformEnt)) { var parent = transformOwner.ParentUid; diff --git a/Content.Shared/Weapons/Melee/SharedMeleeWeaponSystem.cs b/Content.Shared/Weapons/Melee/SharedMeleeWeaponSystem.cs index 767bc179aa..98b9bed6a4 100644 --- a/Content.Shared/Weapons/Melee/SharedMeleeWeaponSystem.cs +++ b/Content.Shared/Weapons/Melee/SharedMeleeWeaponSystem.cs @@ -315,7 +315,7 @@ public abstract class SharedMeleeWeaponSystem : EntitySystem public bool AttemptLightAttack(EntityUid user, EntityUid weaponUid, MeleeWeaponComponent weapon, EntityUid target) { - if (!TryComp(target, out var targetXform)) + if (!TryComp(target, out TransformComponent? targetXform)) return false; return AttemptAttack(user, weaponUid, weapon, new LightAttackEvent(GetNetEntity(target), GetNetEntity(weaponUid), GetNetCoordinates(targetXform.Coordinates)), null); @@ -323,7 +323,7 @@ public abstract class SharedMeleeWeaponSystem : EntitySystem public bool AttemptDisarmAttack(EntityUid user, EntityUid weaponUid, MeleeWeaponComponent weapon, EntityUid target) { - if (!TryComp(target, out var targetXform)) + if (!TryComp(target, out TransformComponent? targetXform)) return false; return AttemptAttack(user, weaponUid, weapon, new DisarmAttackEvent(GetNetEntity(target), GetNetCoordinates(targetXform.Coordinates)), null); @@ -451,7 +451,7 @@ public abstract class SharedMeleeWeaponSystem : EntitySystem // For consistency with wide attacks stuff needs damageable. if (Deleted(target) || !HasComp(target) || - !TryComp(target, out var targetXform) || + !TryComp(target, out TransformComponent? targetXform) || // Not in LOS. !InRange(user, target.Value, component.Range, session)) { @@ -539,7 +539,7 @@ public abstract class SharedMeleeWeaponSystem : EntitySystem private bool DoHeavyAttack(EntityUid user, HeavyAttackEvent ev, EntityUid meleeUid, MeleeWeaponComponent component, ICommonSession? session) { // TODO: This is copy-paste as fuck with DoPreciseAttack - if (!TryComp(user, out var userXform)) + if (!TryComp(user, out TransformComponent? userXform)) return false; var targetMap = GetCoordinates(ev.Coordinates).ToMap(EntityManager, TransformSystem); @@ -753,7 +753,7 @@ public abstract class SharedMeleeWeaponSystem : EntitySystem private void DoLungeAnimation(EntityUid user, EntityUid weapon, Angle angle, MapCoordinates coordinates, float length, string? animation) { // TODO: Assert that offset eyes are still okay. - if (!TryComp(user, out var userXform)) + if (!TryComp(user, out TransformComponent? userXform)) return; var invMatrix = TransformSystem.GetInvWorldMatrix(userXform); diff --git a/Content.Shared/Weapons/Ranged/Systems/SharedGunSystem.Interactions.cs b/Content.Shared/Weapons/Ranged/Systems/SharedGunSystem.Interactions.cs index 274828a208..f3ff89a660 100644 --- a/Content.Shared/Weapons/Ranged/Systems/SharedGunSystem.Interactions.cs +++ b/Content.Shared/Weapons/Ranged/Systems/SharedGunSystem.Interactions.cs @@ -112,6 +112,12 @@ public abstract partial class SharedGunSystem private void OnGunSelected(EntityUid uid, GunComponent component, HandSelectedEvent args) { + if (Timing.ApplyingState) + return; + + if (component.FireRateModified <= 0) + return; + var fireDelay = 1f / component.FireRateModified; if (fireDelay.Equals(0f)) return; diff --git a/Resources/Changelog/Admin.yml b/Resources/Changelog/Admin.yml index 5129de7563..f0bb567102 100644 --- a/Resources/Changelog/Admin.yml +++ b/Resources/Changelog/Admin.yml @@ -222,5 +222,18 @@ Entries: id: 28 time: '2024-05-12T15:07:54.0000000+00:00' url: https://github.com/space-wizards/space-station-14/pull/27883 +- author: Arimah and TsjipTsjip + changes: + - message: Universal access configurator which can modify all access levels with + the correct ID card. + type: Add + - message: Universal ID card which has all access levels. + type: Add + - message: Admin PDA's spawn with a universal ID card, admin ghosts get a universal + access configurator in their bluespace satchel. + type: Tweak + id: 29 + time: '2024-05-19T23:04:16.0000000+00:00' + url: https://github.com/space-wizards/space-station-14/pull/28107 Name: Admin Order: 1 diff --git a/Resources/Changelog/Changelog.yml b/Resources/Changelog/Changelog.yml index 9dffda8901..d20cf44cdb 100644 --- a/Resources/Changelog/Changelog.yml +++ b/Resources/Changelog/Changelog.yml @@ -1,53 +1,4 @@ Entries: -- author: Doctor-Cpu - changes: - - message: Cargo palllets can no longer be ordered from cargo request terminal - type: Remove - id: 6105 - time: '2024-03-07T17:53:57.0000000+00:00' - url: https://github.com/space-wizards/space-station-14/pull/25882 -- author: Beck Thompson - changes: - - message: Lawdrobe has some new items and new ads! - type: Add - id: 6106 - time: '2024-03-07T19:18:39.0000000+00:00' - url: https://github.com/space-wizards/space-station-14/pull/25299 -- author: Blackern5000 - changes: - - message: Salvagers can now pull in overgrown floral anomalies. - type: Add - id: 6107 - time: '2024-03-07T19:37:57.0000000+00:00' - url: https://github.com/space-wizards/space-station-14/pull/24650 -- author: Nimfar11 - changes: - - message: Slimes can now drink FourteenLoko without harming their bodies. - type: Tweak - id: 6108 - time: '2024-03-07T20:50:10.0000000+00:00' - url: https://github.com/space-wizards/space-station-14/pull/25889 -- author: NakataRin - changes: - - message: Evacuation shuttle arrives 10 minutes on green alert now. - type: Tweak - id: 6109 - time: '2024-03-07T21:01:53.0000000+00:00' - url: https://github.com/space-wizards/space-station-14/pull/25906 -- author: Admiral-Obvious-001 - changes: - - message: Zombies are now tougher to kill. - type: Tweak - id: 6110 - time: '2024-03-07T21:02:50.0000000+00:00' - url: https://github.com/space-wizards/space-station-14/pull/25876 -- author: TheShuEd - changes: - - message: Removed Hamlet, Smile and Pun Pun from Thief objectives - type: Remove - id: 6111 - time: '2024-03-07T23:53:36.0000000+00:00' - url: https://github.com/space-wizards/space-station-14/pull/25921 - author: MACMAN2003 changes: - message: Diagonal windows no longer space you when in a pressurized environment. @@ -3868,3 +3819,54 @@ id: 6604 time: '2024-05-19T01:35:46.0000000+00:00' url: https://github.com/space-wizards/space-station-14/pull/27975 +- author: SHOTbyGUN + changes: + - message: White cane recipe for MedFab + type: Add + id: 6605 + time: '2024-05-19T22:22:45.0000000+00:00' + url: https://github.com/space-wizards/space-station-14/pull/28146 +- author: EmoGarbage404 + changes: + - message: Mirrors work again. + type: Fix + id: 6606 + time: '2024-05-19T22:35:55.0000000+00:00' + url: https://github.com/space-wizards/space-station-14/pull/28084 +- author: PolterTzi + changes: + - message: The guidebook now lists the effects reagents have on plants. + type: Add + id: 6607 + time: '2024-05-19T23:01:44.0000000+00:00' + url: https://github.com/space-wizards/space-station-14/pull/28038 +- author: Tayrtahn + changes: + - message: The popup for someone pointing at you is now slightly larger than normal + popups. + type: Tweak + id: 6608 + time: '2024-05-20T13:32:25.0000000+00:00' + url: https://github.com/space-wizards/space-station-14/pull/28152 +- author: Tayrtahn + changes: + - message: '"Warp to most followed" ghost option no longer includes admins and non-ghost + followers.' + type: Fix + id: 6609 + time: '2024-05-20T14:12:05.0000000+00:00' + url: https://github.com/space-wizards/space-station-14/pull/28120 +- author: Killerqu00 + changes: + - message: Sleeper Agents only appear once per round. + type: Tweak + id: 6610 + time: '2024-05-21T10:16:35.0000000+00:00' + url: https://github.com/space-wizards/space-station-14/pull/28160 +- author: TheShuEd + changes: + - message: Artifact portal lifespan reduced from 120 seconds to 1 second + type: Tweak + id: 6611 + time: '2024-05-22T07:52:58.0000000+00:00' + url: https://github.com/space-wizards/space-station-14/pull/28200 diff --git a/Resources/Locale/en-US/entity-systems/pointing/pointing-system.ftl b/Resources/Locale/en-US/entity-systems/pointing/pointing-system.ftl index a310fd9b69..29f0fa27e2 100644 --- a/Resources/Locale/en-US/entity-systems/pointing/pointing-system.ftl +++ b/Resources/Locale/en-US/entity-systems/pointing/pointing-system.ftl @@ -3,7 +3,7 @@ pointing-system-try-point-cannot-reach = You can't reach there! pointing-system-point-at-self = You point at yourself. pointing-system-point-at-other = You point at {THE($other)}. -pointing-system-point-at-self-others = {CAPITALIZE(THE($otherName))} points at {THE($other)}. +pointing-system-point-at-self-others = {CAPITALIZE(THE($otherName))} points at {REFLEXIVE($other)}. pointing-system-point-at-other-others = {CAPITALIZE(THE($otherName))} points at {THE($other)}. pointing-system-point-at-you-other = {$otherName} points at you. pointing-system-point-at-tile = You point at the {$tileName}. diff --git a/Resources/Locale/en-US/guidebook/chemistry/core.ftl b/Resources/Locale/en-US/guidebook/chemistry/core.ftl index 5179915e05..2ffb0b2be2 100644 --- a/Resources/Locale/en-US/guidebook/chemistry/core.ftl +++ b/Resources/Locale/en-US/guidebook/chemistry/core.ftl @@ -15,6 +15,8 @@ guidebook-reagent-sources-ent-wrapper = [bold]{$name}[/bold] \[1\] guidebook-reagent-sources-gas-wrapper = [bold]{$name} (gas)[/bold] \[1\] guidebook-reagent-effects-header = Effects guidebook-reagent-effects-metabolism-group-rate = [bold]{$group}[/bold] [color=gray]({$rate} units per second)[/color] +guidebook-reagent-plant-metabolisms-header = Plant Metabolism +guidebook-reagent-plant-metabolisms-rate = [bold]Plant Metabolism[/bold] [color=gray](1 unit every 3 seconds as base)[/color] guidebook-reagent-physical-description = [italic]Seems to be {$description}.[/italic] guidebook-reagent-recipes-mix-info = {$minTemp -> [0] {$hasMax -> diff --git a/Resources/Locale/en-US/guidebook/chemistry/effects.ftl b/Resources/Locale/en-US/guidebook/chemistry/effects.ftl index 5b449cd520..5579c95e9d 100644 --- a/Resources/Locale/en-US/guidebook/chemistry/effects.ftl +++ b/Resources/Locale/en-US/guidebook/chemistry/effects.ftl @@ -339,7 +339,7 @@ reagent-effect-guidebook-innoculate-zombie-infection = *[other] cure } an ongoing zombie infection, and provides immunity to future infections -reagent-effect-guidebook-reduce-rotting = +reagent-effect-guidebook-reduce-rotting = { $chance -> [1] Regenerates *[other] regenerate @@ -350,3 +350,33 @@ reagent-effect-guidebook-missing = [1] Causes *[other] cause } an unknown effect as nobody has written this effect yet + +reagent-effect-guidebook-plant-attribute = + { $chance -> + [1] Adjusts + *[other] adjust + } {$attribute} by [color={$colorName}]{$amount}[/color] + +reagent-effect-guidebook-plant-cryoxadone = + { $chance -> + [1] Ages back + *[other] age back + } the plant, depending on the plant's age and time to grow + +reagent-effect-guidebook-plant-phalanximine = + { $chance -> + [1] Makes + *[other] make + } a plant not viable due to mutation viable again + +reagent-effect-guidebook-plant-diethylamine = + { $chance -> + [1] Increases + *[other] increase + } the plant's lifespan and/or base health with 10% chance for each. + +reagent-effect-guidebook-plant-robust-harvest = + { $chance -> + [1] Increases + *[other] increase + } the plant's potency by {$increase} up to a maximum of {$limit}. Causes the plant to lose its seeds once the potency reaches {$seedlesstreshold}. Trying to add potency over {$limit} may cause decrease in yield at a 10% chance. diff --git a/Resources/Locale/en-US/guidebook/chemistry/plant-attributes.ftl b/Resources/Locale/en-US/guidebook/chemistry/plant-attributes.ftl new file mode 100644 index 0000000000..2575221008 --- /dev/null +++ b/Resources/Locale/en-US/guidebook/chemistry/plant-attributes.ftl @@ -0,0 +1,9 @@ +plant-attribute-growth = age +plant-attribute-water = water level +plant-attribute-weeds = weeds level +plant-attribute-toxins = toxins level +plant-attribute-nutrition = nutrition level +plant-attribute-mutation-level = mutation level +plant-attribute-pests = pests level +plant-attribute-mutation-mod = mutation modifier +plant-attribute-health = health diff --git a/Resources/Locale/en-US/metabolism/metabolism-groups.ftl b/Resources/Locale/en-US/metabolism/metabolism-groups.ftl index 404d0fc786..b9bd477fbb 100644 --- a/Resources/Locale/en-US/metabolism/metabolism-groups.ftl +++ b/Resources/Locale/en-US/metabolism/metabolism-groups.ftl @@ -5,3 +5,4 @@ metabolism-group-alcohol = Alcohol metabolism-group-food = Food metabolism-group-drink = Drink metabolism-group-gas = Gas +metabolism-group-plant-metabolisms = Plant Metabolism diff --git a/Resources/Prototypes/Catalog/Fills/Backpacks/StarterGear/satchel.yml b/Resources/Prototypes/Catalog/Fills/Backpacks/StarterGear/satchel.yml index 140b1c2968..fe41168829 100644 --- a/Resources/Prototypes/Catalog/Fills/Backpacks/StarterGear/satchel.yml +++ b/Resources/Prototypes/Catalog/Fills/Backpacks/StarterGear/satchel.yml @@ -214,7 +214,7 @@ - id: BoxSurvival - id: Bible - id: RubberStampChaplain - + - type: entity noSpawn: true parent: ClothingBackpackSatchel @@ -296,4 +296,5 @@ contents: - id: GasAnalyzer - id: trayScanner + - id: AccessConfiguratorUniversal - type: Unremoveable diff --git a/Resources/Prototypes/Chemistry/metabolism_groups.yml b/Resources/Prototypes/Chemistry/metabolism_groups.yml index b2035671af..1cc1f19311 100644 --- a/Resources/Prototypes/Chemistry/metabolism_groups.yml +++ b/Resources/Prototypes/Chemistry/metabolism_groups.yml @@ -27,3 +27,8 @@ - type: metabolismGroup id: Gas name: metabolism-group-gas + +# Dummy for the guide +- type: metabolismGroup + id: PlantMetabolisms + name: metabolism-group-plant-metabolisms diff --git a/Resources/Prototypes/Entities/Clothing/Head/base_clothinghead.yml b/Resources/Prototypes/Entities/Clothing/Head/base_clothinghead.yml index e19217686f..40f9e0a3d4 100644 --- a/Resources/Prototypes/Entities/Clothing/Head/base_clothinghead.yml +++ b/Resources/Prototypes/Entities/Clothing/Head/base_clothinghead.yml @@ -131,6 +131,8 @@ #Copies ClothingHeadHardsuitBase behavior equipSound: /Audio/Mecha/mechmove03.ogg unequipSound: /Audio/Mecha/mechmove03.ogg + equipDelay: 2 + unequipDelay: 2 - type: Tag tags: - WhitelistChameleon diff --git a/Resources/Prototypes/Entities/Effects/portal.yml b/Resources/Prototypes/Entities/Effects/portal.yml index eb69ac821f..75300693cd 100644 --- a/Resources/Prototypes/Entities/Effects/portal.yml +++ b/Resources/Prototypes/Entities/Effects/portal.yml @@ -65,7 +65,7 @@ energy: 1 netsync: false - type: TimedDespawn - lifetime: 120 + lifetime: 1 - type: Portal canTeleportToOtherMaps: true diff --git a/Resources/Prototypes/Entities/Mobs/Player/humanoid.yml b/Resources/Prototypes/Entities/Mobs/Player/humanoid.yml index 7a4aedd5e1..c5805f0ed9 100644 --- a/Resources/Prototypes/Entities/Mobs/Player/humanoid.yml +++ b/Resources/Prototypes/Entities/Mobs/Player/humanoid.yml @@ -888,7 +888,7 @@ settings: short - type: GhostTakeoverAvailable - type: Loadout - prototypes: [ SyndicateOperativeGearDisasterVictim ] + prototypes: [ SyndicateOperativeGearCivilian ] - type: RandomMetadata nameSegments: - names_first diff --git a/Resources/Prototypes/Entities/Objects/Devices/forensic_scanner.yml b/Resources/Prototypes/Entities/Objects/Devices/forensic_scanner.yml index 170751766b..a0ada5ebe3 100644 --- a/Resources/Prototypes/Entities/Objects/Devices/forensic_scanner.yml +++ b/Resources/Prototypes/Entities/Objects/Devices/forensic_scanner.yml @@ -9,6 +9,7 @@ state: forensicnew - type: Item size: Small + storedRotation: 90 - type: Clothing sprite: Objects/Devices/forensic_scanner.rsi quickEquip: false diff --git a/Resources/Prototypes/Entities/Objects/Devices/pda.yml b/Resources/Prototypes/Entities/Objects/Devices/pda.yml index 472d0ecbe1..b76ca6a14a 100644 --- a/Resources/Prototypes/Entities/Objects/Devices/pda.yml +++ b/Resources/Prototypes/Entities/Objects/Devices/pda.yml @@ -658,10 +658,11 @@ parent: CentcomPDA id: AdminPDA name: Admin PDA + suffix: Admin description: If you are not an admin please return this PDA to the nearest admin. components: - type: Pda - id: PassengerIDCard + id: UniversalIDCard - type: HealthAnalyzer scanDelay: 0 - type: CartridgeLoader diff --git a/Resources/Prototypes/Entities/Objects/Misc/identification_cards.yml b/Resources/Prototypes/Entities/Objects/Misc/identification_cards.yml index 3de1afe8b8..98ae7df9b3 100644 --- a/Resources/Prototypes/Entities/Objects/Misc/identification_cards.yml +++ b/Resources/Prototypes/Entities/Objects/Misc/identification_cards.yml @@ -840,3 +840,30 @@ layers: - state: default - state: idseniorofficer + +- type: entity + parent: IDCardStandard + id: UniversalIDCard + name: universal ID card + suffix: Admin + description: An ID card that gives you access beyond your wildest dreams. + components: + - type: Sprite + sprite: Objects/Misc/id_cards.rsi + layers: + - state: admin + - state: idadmin + - type: Clothing + sprite: Objects/Misc/id_cards.rsi + - type: Item + heldPrefix: green + - type: IdCard + jobTitle: Universal + jobIcon: JobIconAdmin + - type: Access + groups: + - AllAccess + tags: + - CentralCommand + - NuclearOperative + - SyndicateAgent diff --git a/Resources/Prototypes/Entities/Objects/Tools/access_configurator.yml b/Resources/Prototypes/Entities/Objects/Tools/access_configurator.yml index d63e1f0aa9..3c5bc93b42 100644 --- a/Resources/Prototypes/Entities/Objects/Tools/access_configurator.yml +++ b/Resources/Prototypes/Entities/Objects/Tools/access_configurator.yml @@ -73,3 +73,61 @@ - type: ContainerContainer containers: AccessOverrider-privilegedId: !type:ContainerSlot + +- type: entity + parent: AccessConfigurator + id: AccessConfiguratorUniversal + name: universal access configurator + suffix: Admin + description: A modified access configurator used only by the mythical Administrator. + components: + - type: Sprite + sprite: Objects/Tools/universal_access_configurator.rsi + - type: Clothing + sprite: Objects/Tools/universal_access_configurator.rsi + - type: AccessOverrider + accessLevels: + - Armory + - Atmospherics + - Bar + - Brig + - Detective + - Captain + - Cargo + - Chapel + - Chemistry + - ChiefEngineer + - ChiefMedicalOfficer + - Command + - Engineering + - External + - HeadOfPersonnel + - HeadOfSecurity + - Hydroponics + - Janitor + - Kitchen + - Lawyer + - Maintenance + - Medical + - Quartermaster + - Research + - ResearchDirector + - Salvage + - Security + - Service + - Theatre + - CentralCommand + - NuclearOperative + - SyndicateAgent + privilegedIdSlot: + name: id-card-console-privileged-id + ejectSound: /Audio/Machines/id_swipe.ogg + insertSound: /Audio/Weapons/Guns/MagIn/batrifle_magin.ogg + ejectOnBreak: true + swap: false + whitelist: + components: + - IdCard + denialSound: + path: /Audio/Machines/custom_deny.ogg + doAfter: 0.5 diff --git a/Resources/Prototypes/Entities/Structures/Furniture/toilet.yml b/Resources/Prototypes/Entities/Structures/Furniture/toilet.yml index 2556b9ddfd..1eb5176e9e 100644 --- a/Resources/Prototypes/Entities/Structures/Furniture/toilet.yml +++ b/Resources/Prototypes/Entities/Structures/Furniture/toilet.yml @@ -51,6 +51,17 @@ disposals: !type:Container - type: Physics bodyType: Static + - type: Fixtures + fixtures: + fix1: + shape: + !type:PhysShapeCircle + radius: 0.4 + density: 190 + mask: + - MachineMask + layer: + - None - type: Construction graph: Toilet node: toilet diff --git a/Resources/Prototypes/Entities/Structures/Machines/lathe.yml b/Resources/Prototypes/Entities/Structures/Machines/lathe.yml index 8305fc5a90..575144a2c2 100644 --- a/Resources/Prototypes/Entities/Structures/Machines/lathe.yml +++ b/Resources/Prototypes/Entities/Structures/Machines/lathe.yml @@ -910,6 +910,7 @@ - Saw - Hemostat - ClothingEyesGlassesChemical + - WhiteCane dynamicRecipes: - ChemicalPayload - CryostasisBeaker diff --git a/Resources/Prototypes/Entities/Structures/Wallmounts/mirror.yml b/Resources/Prototypes/Entities/Structures/Wallmounts/mirror.yml index d02bce020d..1fe3318ef5 100644 --- a/Resources/Prototypes/Entities/Structures/Wallmounts/mirror.yml +++ b/Resources/Prototypes/Entities/Structures/Wallmounts/mirror.yml @@ -11,7 +11,12 @@ - type: Clickable - type: Transform anchored: true - - type: MagicMirror + - type: MagicMirror #instant and silent + changeHairSound: null + addSlotTime: 0 + removeSlotTime: 0 + selectSlotTime: 0 + changeSlotTime: 0 - type: ActivatableUI key: enum.MagicMirrorUiKey.Key - type: UserInterface diff --git a/Resources/Prototypes/GameRules/events.yml b/Resources/Prototypes/GameRules/events.yml index 19c9f7d5dc..3b9ad5aadf 100644 --- a/Resources/Prototypes/GameRules/events.yml +++ b/Resources/Prototypes/GameRules/events.yml @@ -433,10 +433,10 @@ noSpawn: true components: - type: StationEvent - earliestStart: 25 + earliestStart: 30 weight: 8 minimumPlayers: 15 - reoccurrenceDelay: 30 + maxOccurrences: 1 # can only happen once per round startAnnouncement: station-event-communication-interception startAudio: path: /Audio/Announcements/intercept.ogg diff --git a/Resources/Prototypes/Recipes/Lathes/medical.yml b/Resources/Prototypes/Recipes/Lathes/medical.yml index bebfa4924a..b1a2e6df1d 100644 --- a/Resources/Prototypes/Recipes/Lathes/medical.yml +++ b/Resources/Prototypes/Recipes/Lathes/medical.yml @@ -234,3 +234,10 @@ Steel: 600 Plastic: 300 +- type: latheRecipe + id: WhiteCane + result: WhiteCane + completetime: 2 + materials: + Steel: 100 + Plastic: 100 diff --git a/Resources/Prototypes/Roles/Jobs/Fun/misc_startinggear.yml b/Resources/Prototypes/Roles/Jobs/Fun/misc_startinggear.yml index 181746a64a..d4cfc3e29c 100644 --- a/Resources/Prototypes/Roles/Jobs/Fun/misc_startinggear.yml +++ b/Resources/Prototypes/Roles/Jobs/Fun/misc_startinggear.yml @@ -79,19 +79,9 @@ back: ClothingBackpackDuffelSyndicate shoes: ClothingShoesBootsCombat gloves: ClothingHandsGlovesColorBlack - -# Syndicate Operative Outfit - Disaster Victim -- type: startingGear - id: SyndicateOperativeGearDisasterVictim - equipment: - jumpsuit: ClothingUniformJumpsuitSyndieFormal - back: ClothingBackpackDuffelSyndicate - shoes: ClothingShoesBootsCombat - gloves: ClothingHandsGlovesColorBlack id: SyndiPDA ears: ClothingHeadsetAltSyndicate - #Syndicate Operative Outfit - Basic - type: startingGear id: SyndicateOperativeGearBasic diff --git a/Resources/Prototypes/StatusEffects/job.yml b/Resources/Prototypes/StatusEffects/job.yml index aec3f5e69d..6275f0bc07 100644 --- a/Resources/Prototypes/StatusEffects/job.yml +++ b/Resources/Prototypes/StatusEffects/job.yml @@ -375,3 +375,10 @@ icon: sprite: /Textures/Interface/Misc/job_icons.rsi state: Visitor + +- type: statusIcon + parent: JobIcon + id: JobIconAdmin + icon: + sprite: /Textures/Interface/Misc/job_icons.rsi + state: Admin diff --git a/Resources/Textures/Interface/Misc/job_icons.rsi/Admin.png b/Resources/Textures/Interface/Misc/job_icons.rsi/Admin.png new file mode 100644 index 0000000000..38a76df8d8 Binary files /dev/null and b/Resources/Textures/Interface/Misc/job_icons.rsi/Admin.png differ diff --git a/Resources/Textures/Interface/Misc/job_icons.rsi/meta.json b/Resources/Textures/Interface/Misc/job_icons.rsi/meta.json index 745cc43b84..fff9f78288 100644 --- a/Resources/Textures/Interface/Misc/job_icons.rsi/meta.json +++ b/Resources/Textures/Interface/Misc/job_icons.rsi/meta.json @@ -1,7 +1,7 @@ { "version": 1, "license": "CC-BY-SA-3.0", - "copyright": "Taken from https://github.com/vgstation-coders/vgstation13/blob/e71d6c4fba5a51f99b81c295dcaec4fc2f58fb19/icons/mob/screen1.dmi | Brigmedic icon made by PuroSlavKing (Github) | Zombie icon made by RamZ | Zookeper by netwy (discort) | Rev and Head Rev icon taken from https://tgstation13.org/wiki/HUD and edited by coolmankid12345 (Discord) | Mindshield icon taken from https://github.com/tgstation/tgstation/blob/master/icons/mob/huds/hud.dmi", + "copyright": "Taken from https://github.com/vgstation-coders/vgstation13/blob/e71d6c4fba5a51f99b81c295dcaec4fc2f58fb19/icons/mob/screen1.dmi | Brigmedic icon made by PuroSlavKing (Github) | Zombie icon made by RamZ | Zookeper by netwy (discort) | Rev and Head Rev icon taken from https://tgstation13.org/wiki/HUD and edited by coolmankid12345 (Discord) | Mindshield icon taken from https://github.com/tgstation/tgstation/blob/master/icons/mob/huds/hud.dmi | Admin recolored from MedicalIntern by TsjipTsjip", "size": { "x": 8, @@ -185,6 +185,9 @@ }, { "name": "InitialInfected" + }, + { + "name": "Admin" } ] } diff --git a/Resources/Textures/Objects/Misc/id_cards.rsi/admin.png b/Resources/Textures/Objects/Misc/id_cards.rsi/admin.png new file mode 100644 index 0000000000..99ca993b0b Binary files /dev/null and b/Resources/Textures/Objects/Misc/id_cards.rsi/admin.png differ diff --git a/Resources/Textures/Objects/Misc/id_cards.rsi/green-inhand-left.png b/Resources/Textures/Objects/Misc/id_cards.rsi/green-inhand-left.png new file mode 100644 index 0000000000..958c3ba056 Binary files /dev/null and b/Resources/Textures/Objects/Misc/id_cards.rsi/green-inhand-left.png differ diff --git a/Resources/Textures/Objects/Misc/id_cards.rsi/green-inhand-right.png b/Resources/Textures/Objects/Misc/id_cards.rsi/green-inhand-right.png new file mode 100644 index 0000000000..218d68ef5f Binary files /dev/null and b/Resources/Textures/Objects/Misc/id_cards.rsi/green-inhand-right.png differ diff --git a/Resources/Textures/Objects/Misc/id_cards.rsi/idadmin.png b/Resources/Textures/Objects/Misc/id_cards.rsi/idadmin.png new file mode 100644 index 0000000000..3705c6bf4e Binary files /dev/null and b/Resources/Textures/Objects/Misc/id_cards.rsi/idadmin.png differ diff --git a/Resources/Textures/Objects/Misc/id_cards.rsi/idzookeeper.png b/Resources/Textures/Objects/Misc/id_cards.rsi/idzookeeper.png index c24212aab8..aa82cb3cb6 100644 Binary files a/Resources/Textures/Objects/Misc/id_cards.rsi/idzookeeper.png and b/Resources/Textures/Objects/Misc/id_cards.rsi/idzookeeper.png differ diff --git a/Resources/Textures/Objects/Misc/id_cards.rsi/meta.json b/Resources/Textures/Objects/Misc/id_cards.rsi/meta.json index a84c76a46c..bf76784bb9 100644 --- a/Resources/Textures/Objects/Misc/id_cards.rsi/meta.json +++ b/Resources/Textures/Objects/Misc/id_cards.rsi/meta.json @@ -1,7 +1,7 @@ { "version": 1, "license": "CC-BY-SA-3.0", - "copyright": "Taken from tgstation at commit https://github.com/tgstation/tgstation/commit/d917f4c2a088419d5c3aec7656b7ff8cebd1822e idcluwne made by brainfood1183 (github) for ss14, idbrigmedic made by PuroSlavKing (Github), pirate made by brainfood1183 (github)", + "copyright": "Taken from tgstation at commit https://github.com/tgstation/tgstation/commit/d917f4c2a088419d5c3aec7656b7ff8cebd1822e idcluwne made by brainfood1183 (github) for ss14, idbrigmedic made by PuroSlavKing (Github), pirate made by brainfood1183 (github), idadmin made by Arimah (github)", "size": { "x": 32, "y": 32 @@ -13,6 +13,9 @@ { "name": "centcom" }, + { + "name": "admin" + }, { "name": "ert_chaplain" }, @@ -169,6 +172,9 @@ { "name": "idintern-tech" }, + { + "name": "idadmin" + }, { "name": "orange" }, @@ -256,6 +262,14 @@ { "name": "blue-inhand-right", "directions": 4 + }, + { + "name": "green-inhand-left", + "directions": 4 + }, + { + "name": "green-inhand-right", + "directions": 4 } ] } diff --git a/Resources/Textures/Objects/Tools/universal_access_configurator.rsi/equipped-BELT.png b/Resources/Textures/Objects/Tools/universal_access_configurator.rsi/equipped-BELT.png new file mode 100644 index 0000000000..b80e5e0055 Binary files /dev/null and b/Resources/Textures/Objects/Tools/universal_access_configurator.rsi/equipped-BELT.png differ diff --git a/Resources/Textures/Objects/Tools/universal_access_configurator.rsi/icon.png b/Resources/Textures/Objects/Tools/universal_access_configurator.rsi/icon.png new file mode 100644 index 0000000000..4b0331deab Binary files /dev/null and b/Resources/Textures/Objects/Tools/universal_access_configurator.rsi/icon.png differ diff --git a/Resources/Textures/Objects/Tools/universal_access_configurator.rsi/inhand-left.png b/Resources/Textures/Objects/Tools/universal_access_configurator.rsi/inhand-left.png new file mode 100644 index 0000000000..5fe2029ac5 Binary files /dev/null and b/Resources/Textures/Objects/Tools/universal_access_configurator.rsi/inhand-left.png differ diff --git a/Resources/Textures/Objects/Tools/universal_access_configurator.rsi/inhand-right.png b/Resources/Textures/Objects/Tools/universal_access_configurator.rsi/inhand-right.png new file mode 100644 index 0000000000..17951b1407 Binary files /dev/null and b/Resources/Textures/Objects/Tools/universal_access_configurator.rsi/inhand-right.png differ diff --git a/Resources/Textures/Objects/Tools/universal_access_configurator.rsi/meta.json b/Resources/Textures/Objects/Tools/universal_access_configurator.rsi/meta.json new file mode 100644 index 0000000000..b2332c597a --- /dev/null +++ b/Resources/Textures/Objects/Tools/universal_access_configurator.rsi/meta.json @@ -0,0 +1,62 @@ +{ + "version": 1, + "license": "CC-BY-SA-3.0", + "copyright": "Recoloured by Arimah from the access configurator at https://github.com/space-wizards/space-station-14/commit/fd7db8004e6d5cf442168152a0ca6af1051263eb", + "size": { + "x": 32, + "y": 32 + }, + "states": [ + { + "name": "icon", + "delays": [ + [ + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1, + 0.1 + ] + ] + }, + { + "name": "inhand-left", + "directions": 4 + }, + { + "name": "inhand-right", + "directions": 4 + }, + { + "name": "equipped-BELT", + "directions": 4 + } + ] +} diff --git a/Resources/Textures/Structures/Furniture/toilet.rsi/condisposal.png b/Resources/Textures/Structures/Furniture/toilet.rsi/condisposal.png index c60cabe80b..469258bd2f 100644 Binary files a/Resources/Textures/Structures/Furniture/toilet.rsi/condisposal.png and b/Resources/Textures/Structures/Furniture/toilet.rsi/condisposal.png differ diff --git a/Resources/Textures/Structures/Furniture/toilet.rsi/disposal-charging.png b/Resources/Textures/Structures/Furniture/toilet.rsi/disposal-charging.png index cb9ad3a9c7..d12b97d998 100644 Binary files a/Resources/Textures/Structures/Furniture/toilet.rsi/disposal-charging.png and b/Resources/Textures/Structures/Furniture/toilet.rsi/disposal-charging.png differ diff --git a/Resources/Textures/Structures/Furniture/toilet.rsi/disposal-flush.png b/Resources/Textures/Structures/Furniture/toilet.rsi/disposal-flush.png index 811284448c..3afc757cf9 100644 Binary files a/Resources/Textures/Structures/Furniture/toilet.rsi/disposal-flush.png and b/Resources/Textures/Structures/Furniture/toilet.rsi/disposal-flush.png differ diff --git a/Resources/Textures/Structures/Furniture/toilet.rsi/disposal.png b/Resources/Textures/Structures/Furniture/toilet.rsi/disposal.png index cb2db2f9d8..de472b8e7c 100644 Binary files a/Resources/Textures/Structures/Furniture/toilet.rsi/disposal.png and b/Resources/Textures/Structures/Furniture/toilet.rsi/disposal.png differ