clean up a bunch of R&D code (#13071)
* clean up a bunch of R&D code * don't store components * brug * speedrun some sloth review
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
using Content.Shared.Interaction;
|
||||
using Content.Server.Research.Components;
|
||||
using Content.Server.Popups;
|
||||
using Content.Server.Research.Systems;
|
||||
using Robust.Shared.Player;
|
||||
|
||||
namespace Content.Server.Research.Disk
|
||||
@@ -8,6 +9,7 @@ namespace Content.Server.Research.Disk
|
||||
public sealed class ResearchDiskSystem : EntitySystem
|
||||
{
|
||||
[Dependency] private readonly PopupSystem _popupSystem = default!;
|
||||
[Dependency] private readonly ResearchSystem _research = default!;
|
||||
public override void Initialize()
|
||||
{
|
||||
base.Initialize();
|
||||
@@ -22,7 +24,7 @@ namespace Content.Server.Research.Disk
|
||||
if (!TryComp<ResearchServerComponent>(args.Target, out var server))
|
||||
return;
|
||||
|
||||
server.Points += component.Points;
|
||||
_research.ChangePointsOnServer(server.Owner, component.Points, server);
|
||||
_popupSystem.PopupEntity(Loc.GetString("research-disk-inserted", ("points", component.Points)), args.Target.Value, args.User);
|
||||
EntityManager.QueueDeleteEntity(uid);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user