From a29e004eba51b5ca67698356ae0d336abf15b721 Mon Sep 17 00:00:00 2001 From: Aviu00 <93730715+Aviu00@users.noreply.github.com> Date: Sun, 8 Oct 2023 19:43:45 +0900 Subject: [PATCH] =?UTF-8?q?=D0=92=D1=81=D1=8F=D0=BA=D0=BE=D0=B5=20(#474)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Economy price tweaks * Fix slang & crit radio & explosion immunity & tweak spiders and slimes * Fix vending message * Typo * Style --- .../Chat/Managers/ChatSanitizationManager.cs | 2 +- Content.Server/Mobs/CritMobActionsSystem.cs | 6 ++- .../Locale/ru-RU/white/economy/vending.ftl | 1 + .../Prototypes/Entities/Mobs/NPCs/slimes.yml | 1 + .../Consumable/Drinks/drinks_bottles.yml | 2 + .../Consumable/Food/Containers/box.yml | 2 + .../Structures/Machines/vending_machines.yml | 1 - .../Entities/Structures/Storage/morgue.yml | 40 +++++++++++++++++++ 8 files changed, 52 insertions(+), 3 deletions(-) diff --git a/Content.Server/Chat/Managers/ChatSanitizationManager.cs b/Content.Server/Chat/Managers/ChatSanitizationManager.cs index 51694e6f88..168fe5e5e7 100644 --- a/Content.Server/Chat/Managers/ChatSanitizationManager.cs +++ b/Content.Server/Chat/Managers/ChatSanitizationManager.cs @@ -139,7 +139,7 @@ public sealed class ChatSanitizationManager : IChatSanitizationManager //WD-EDIT public string SanitizeOutSlang(string input) { - var pattern = @"([\?\!\p{L}\d'`-]+)"; + var pattern = @"(^\!|^\?|[\p{L}\d'`-]+)"; var newMessage = Regex.Replace(input, pattern , match => _slangToNormal.ContainsKey(match.Groups[1].Value.ToLower()) ? _slangToNormal[match.Groups[1].Value.ToLower()] : match.Value, RegexOptions.IgnoreCase); diff --git a/Content.Server/Mobs/CritMobActionsSystem.cs b/Content.Server/Mobs/CritMobActionsSystem.cs index 8dd8274d10..be795756bc 100644 --- a/Content.Server/Mobs/CritMobActionsSystem.cs +++ b/Content.Server/Mobs/CritMobActionsSystem.cs @@ -75,7 +75,11 @@ public sealed class CritMobActionsSystem : EntitySystem } lastWords += "..."; - _chat.TrySendInGameICMessage(uid, lastWords, InGameICChatType.Whisper, ChatTransmitRange.Normal, checkRadioPrefix: false, ignoreActionBlocker: true); + // WD EDIT START + _chat.TryProccessRadioMessage(uid, lastWords, out var output, out _); + _chat.TrySendInGameICMessage(uid, output, InGameICChatType.Whisper, ChatTransmitRange.Normal, checkRadioPrefix: false, ignoreActionBlocker: true); + // WD EDIT END + _host.ExecuteCommand(actor.PlayerSession, "ghost"); }); diff --git a/Resources/Locale/ru-RU/white/economy/vending.ftl b/Resources/Locale/ru-RU/white/economy/vending.ftl index 9c50a1bdd3..2cb92fda90 100644 --- a/Resources/Locale/ru-RU/white/economy/vending.ftl +++ b/Resources/Locale/ru-RU/white/economy/vending.ftl @@ -1 +1,2 @@ vending-ui-credits-amount = Кредитов в автомате: { $credits } +vending-machine-component-no-balance = Недостаточно средств. diff --git a/Resources/Prototypes/Entities/Mobs/NPCs/slimes.yml b/Resources/Prototypes/Entities/Mobs/NPCs/slimes.yml index 22f476cebf..a047912dc2 100644 --- a/Resources/Prototypes/Entities/Mobs/NPCs/slimes.yml +++ b/Resources/Prototypes/Entities/Mobs/NPCs/slimes.yml @@ -42,6 +42,7 @@ volume: 3 - type: Tag tags: + - DoorBumpOpener - FootstepSound - type: Butcherable butcheringType: Knife diff --git a/Resources/Prototypes/Entities/Objects/Consumable/Drinks/drinks_bottles.yml b/Resources/Prototypes/Entities/Objects/Consumable/Drinks/drinks_bottles.yml index 158a20461b..97a911f0d3 100644 --- a/Resources/Prototypes/Entities/Objects/Consumable/Drinks/drinks_bottles.yml +++ b/Resources/Prototypes/Entities/Objects/Consumable/Drinks/drinks_bottles.yml @@ -73,6 +73,8 @@ - type: PhysicalComposition materialComposition: Glass: 100 + - type: StaticPrice + price: 50 - type: entity parent: DrinkBottleGlassBaseFull diff --git a/Resources/Prototypes/Entities/Objects/Consumable/Food/Containers/box.yml b/Resources/Prototypes/Entities/Objects/Consumable/Food/Containers/box.yml index 6b0e43fd10..4c80914e21 100644 --- a/Resources/Prototypes/Entities/Objects/Consumable/Food/Containers/box.yml +++ b/Resources/Prototypes/Entities/Objects/Consumable/Food/Containers/box.yml @@ -530,6 +530,8 @@ - id: GoldenBikeHorn prob: 0.1 orGroup: GiftPool + - type: StaticPrice + price: 30 - type: entity id: HappyHonkMime diff --git a/Resources/Prototypes/Entities/Structures/Machines/vending_machines.yml b/Resources/Prototypes/Entities/Structures/Machines/vending_machines.yml index 1f0e6ea83d..3b2b449bb3 100644 --- a/Resources/Prototypes/Entities/Structures/Machines/vending_machines.yml +++ b/Resources/Prototypes/Entities/Structures/Machines/vending_machines.yml @@ -952,7 +952,6 @@ normalState: normal-unshaded ejectState: eject-unshaded denyState: deny-unshaded - priceMultiplier: 1.0 - type: Sprite sprite: Structures/Machines/VendingMachines/sustenance.rsi layers: diff --git a/Resources/Prototypes/Entities/Structures/Storage/morgue.yml b/Resources/Prototypes/Entities/Structures/Storage/morgue.yml index 725f4c9b0f..cdbc5bd6ca 100644 --- a/Resources/Prototypes/Entities/Structures/Storage/morgue.yml +++ b/Resources/Prototypes/Entities/Structures/Storage/morgue.yml @@ -71,6 +71,26 @@ - type: AntiRottingContainer - type: StaticPrice price: 200 + - type: Damageable + damageContainer: Inorganic + damageModifierSet: Metallic + - type: Destructible + thresholds: + - trigger: + !type:DamageTrigger + damage: 200 + behaviors: + - !type:DoActsBehavior + acts: [ "Destruction" ] + - trigger: + !type:DamageTrigger + damage: 100 + behaviors: + - !type:DoActsBehavior + acts: ["Destruction"] + - !type:PlaySoundBehavior + sound: + path: /Audio/Effects/metalbreak.ogg - type: entity id: Crematorium @@ -141,3 +161,23 @@ False: { visible: false } - type: Transform anchored: true + - type: Damageable + damageContainer: Inorganic + damageModifierSet: Metallic + - type: Destructible + thresholds: + - trigger: + !type:DamageTrigger + damage: 200 + behaviors: + - !type:DoActsBehavior + acts: [ "Destruction" ] + - trigger: + !type:DamageTrigger + damage: 100 + behaviors: + - !type:DoActsBehavior + acts: ["Destruction"] + - !type:PlaySoundBehavior + sound: + path: /Audio/Effects/metalbreak.ogg