RND Rework [Death to Techweb] (#16370)
* Techweb rework * more ui work * finishing ui * Finish all the C# logic * the techs + lathes * remove old-tech * mirror-review
This commit is contained in:
24
Content.Client/Research/UI/MiniTechnologyCardControl.xaml.cs
Normal file
24
Content.Client/Research/UI/MiniTechnologyCardControl.xaml.cs
Normal file
@@ -0,0 +1,24 @@
|
||||
using Content.Shared.Research.Prototypes;
|
||||
using Robust.Client.AutoGenerated;
|
||||
using Robust.Client.GameObjects;
|
||||
using Robust.Client.UserInterface;
|
||||
using Robust.Client.UserInterface.XAML;
|
||||
using Robust.Shared.Prototypes;
|
||||
using Robust.Shared.Utility;
|
||||
|
||||
namespace Content.Client.Research.UI;
|
||||
|
||||
[GenerateTypedNameReferences]
|
||||
public sealed partial class MiniTechnologyCardControl : Control
|
||||
{
|
||||
public MiniTechnologyCardControl(TechnologyPrototype technology, IPrototypeManager prototypeManager, SpriteSystem spriteSys, FormattedMessage description)
|
||||
{
|
||||
RobustXamlLoader.Load(this);
|
||||
|
||||
var discipline = prototypeManager.Index<TechDisciplinePrototype>(technology.Discipline);
|
||||
Background.ModulateSelfOverride = discipline.Color;
|
||||
Texture.Texture = spriteSys.Frame0(technology.Icon);
|
||||
NameLabel.SetMessage(Loc.GetString(technology.Name));
|
||||
Main.ToolTip = description.ToString();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user