Exemple #1
0
 public StatusControl(StackComponent parent)
 {
     _parent = parent;
     _label  = new RichTextLabel {
         StyleClasses = { StyleNano.StyleClassItemStatus }
     };
     _label.SetMarkup(Loc.GetString("comp-stack-status", ("count", _parent.Count)));
     AddChild(_label);
 }
Exemple #2
0
            public StatusControl(StackComponent parent)
            {
                _parent = parent;
                _label  = new RichTextLabel {
                    StyleClasses = { StyleNano.StyleClassItemStatus }
                };
                AddChild(_label);

                parent._uiUpdateNeeded = true;
            }
 private void OnStackCountChanged(EntityUid uid, StackComponent component, StackCountChangedEvent args)
 {
     // Dirty the UI now that the stack count has changed.
     component.UiUpdateNeeded = true;
 }
 private void OnStackCountChanged(EntityUid uid, StackComponent component, StackCountChangedEvent args)
 {
     // Dirty the UI now that the stack count has changed.
     component.DirtyUI();
 }