@using Sandbox.UI @using Sasalka @inherits Sandbox.UI.Panel @namespace Sasalka.Ui @if ( Item.Definition.ImageTexture.IsValid() ) { @Item.Definition.Name } else if ( Item.Definition.ImageUrl.Length > 0 ) { @Item.Definition.Name }
@Item?.Definition.Name
@Item?.Count / @Item?.MaxCount
@code { public Sasalka.InventoryItem Item { get; set; } public Action OnItemClick { get; set; } public bool Equipped { get; set; } protected override int BuildHash() { base.BuildHash(); var hash = new HashCode(); hash.Add( Item.Count ); return hash.ToHashCode(); } }