]> git.smokeofanarchy.ru Git - space-station-14.git/commitdiff
restructure cognizine effect so creatures that have minds can talk (#14695)
authordeltanedas <39013340+deltanedas@users.noreply.github.com>
Mon, 20 Mar 2023 00:47:06 +0000 (00:47 +0000)
committerGitHub <noreply@github.com>
Mon, 20 Mar 2023 00:47:06 +0000 (17:47 -0700)
Co-authored-by: deltanedas <@deltanedas:kde.org>
Content.Server/Chemistry/ReagentEffects/MakeSentient.cs

index c98f83876170bfeb849b3936e8ef5a3dbf0cbcbd..c762ba8a83c47bc0a3395464127f2a62f98ad731 100644 (file)
@@ -13,18 +13,18 @@ public sealed class MakeSentient : ReagentEffect
         var entityManager = args.EntityManager;
         var uid = args.SolutionEntity;
 
-        // This makes it so it doesn't affect things that are already sentient
-        if (entityManager.HasComponent<MindComponent>(uid))
-        {
-            return;
-        }
-
         // This piece of code makes things able to speak "normally". One thing of note is that monkeys have a unique accent and won't be affected by this.
         entityManager.RemoveComponent<ReplacementAccentComponent>(uid);
 
-        // Monke talk
+        // Monke talk. This makes cognizine a cure to AMIV's long term damage funnily enough, do with this information what you will.
         entityManager.RemoveComponent<MonkeyAccentComponent>(uid);
 
+        // This makes it so it doesn't add a ghost role to things that are already sentient
+        if (entityManager.HasComponent<MindComponent>(uid))
+        {
+            return;
+        }
+
         // No idea what anything past this point does
         if (entityManager.TryGetComponent(uid, out GhostTakeoverAvailableComponent? takeOver))
         {