VendingMachineItem.xaml.cs 567 B

123456789101112131415161718192021222324
  1. using Robust.Client.AutoGenerated;
  2. using Robust.Client.UserInterface.Controls;
  3. using Robust.Client.UserInterface.XAML;
  4. using Robust.Shared.Prototypes;
  5. namespace Content.Client.VendingMachines.UI;
  6. [GenerateTypedNameReferences]
  7. public sealed partial class VendingMachineItem : BoxContainer
  8. {
  9. public VendingMachineItem(EntProtoId entProto, string text)
  10. {
  11. RobustXamlLoader.Load(this);
  12. ItemPrototype.SetPrototype(entProto);
  13. NameLabel.Text = text;
  14. }
  15. public void SetText(string text)
  16. {
  17. NameLabel.Text = text;
  18. }
  19. }