]> git.smokeofanarchy.ru Git - space-station-14.git/commitdiff
Remove unnecessary dependency injection from DoAfters (#15170)
authorLeon Friedrich <60421075+ElectroJr@users.noreply.github.com>
Tue, 11 Apr 2023 17:23:04 +0000 (05:23 +1200)
committerGitHub <noreply@github.com>
Tue, 11 Apr 2023 17:23:04 +0000 (03:23 +1000)
Content.Shared/DoAfter/SharedDoAfterSystem.Update.cs

index 71a09c700a89900f6cb937a8926c56cd9e1033cd..c47d9c67739b47cad3ca39d688db7625e5b3b04c 100644 (file)
@@ -87,7 +87,7 @@ public abstract partial class SharedDoAfterSystem : EntitySystem
             // I feel like this is somewhat cursed, but its the only way I can think of without having to just send
             // redundant data over the network and increasing DoAfter boilerplate.
             var evType = typeof(DoAfterAttemptEvent<>).MakeGenericType(args.Event.GetType());
-            doAfter.AttemptEvent = _factory.CreateInstance(evType, new object[] { doAfter, args.Event });
+            doAfter.AttemptEvent = _factory.CreateInstance(evType, new object[] { doAfter, args.Event }, inject: false);
         }
 
         if (args.EventTarget != null)