Files
OldThink/Content.Client/White/Reputation/ReputationManager.cs
HitPanda 7c9bd1d934 [Feat] Респект и уважуха (#476)
* db

* wd comment

* manager & commands

* system & round end results

* raise ban event

* client manager & cached values

* role pick tweak

* tweak last commit

* more fixes

* weights fix

* Fix for short rounds

* tweak in cached dictionary

* reva pick system

* fix last commit

* cult role pick

* nukeops role picking

* fix cache in async & show command

* ooc msg show value

* move pick method to manager & traitor pick fix
2024-01-25 08:05:48 +03:00

24 lines
564 B
C#

using System.Diagnostics.CodeAnalysis;
using Content.Shared.White.Reputation;
using Robust.Shared.Network;
namespace Content.Client.White.Reputation;
public sealed class ReputationManager
{
[Dependency] private readonly IClientNetManager _netMgr = default!;
private ReputationInfo? _info;
public void Initialize()
{
_netMgr.RegisterNetMessage<ReputationNetMsg>(msg => _info = msg.Info);
}
public bool TryGetInfo([NotNullWhen(true)] out float? value)
{
value = _info?.Value;
return _info != null;
}
}