41 lines
2.2 KiB
C#
41 lines
2.2 KiB
C#
namespace BlueLaminate.Scraper.Skins;
|
|
|
|
/// <summary>A single CS2 skin from the CSGO-API static catalogue (skins.json).</summary>
|
|
/// <param name="Id">Stable catalogue id, e.g. "skin-e757fd7191f9". Globally unique natural key.</param>
|
|
/// <param name="WeaponName">Owning weapon, e.g. "AK-47", "Hand Wraps", "Bayonet".</param>
|
|
/// <param name="DefIndex">CS weapon definition index (weapon.weapon_id), e.g. AK-47=7. Null if absent.</param>
|
|
/// <param name="PaintIndex">Paint index identifying the finish, e.g. 985. Null if absent.</param>
|
|
/// <param name="Category">Weapon category, e.g. "Rifles", "Knives", "Gloves". Becomes the weapon type.</param>
|
|
/// <param name="Team">"CT", "T", or "Both".</param>
|
|
/// <param name="Name">Skin/pattern name, e.g. "Dragon Lore"; "Vanilla" for knives with no finish.</param>
|
|
/// <param name="Rarity">Rarity tier, e.g. "Covert", "Classified", "Extraordinary".</param>
|
|
/// <param name="Description">Flavour/description text, or null.</param>
|
|
/// <param name="ImageUrl">Catalogue image URL, or null.</param>
|
|
/// <param name="StatTrakAvailable">True if a StatTrak variant exists.</param>
|
|
/// <param name="SouvenirAvailable">True if a Souvenir variant exists.</param>
|
|
/// <param name="FloatMin">Minimum wear value, or null when the catalogue gives none (e.g. vanilla knives).</param>
|
|
/// <param name="FloatMax">Maximum wear value, or null.</param>
|
|
/// <param name="Sources">Collections and containers this skin belongs to.</param>
|
|
public sealed record CatalogSkin(
|
|
string Id,
|
|
string WeaponName,
|
|
int? DefIndex,
|
|
int? PaintIndex,
|
|
string Category,
|
|
string Team,
|
|
string Name,
|
|
string Rarity,
|
|
string? Description,
|
|
string? ImageUrl,
|
|
bool StatTrakAvailable,
|
|
bool SouvenirAvailable,
|
|
decimal? FloatMin,
|
|
decimal? FloatMax,
|
|
IReadOnlyList<CatalogSource> Sources);
|
|
|
|
/// <summary>A collection or container a skin originates from.</summary>
|
|
/// <param name="Id">Stable catalogue id, e.g. "collection-set-community-37" or "crate-4288". Natural key.</param>
|
|
/// <param name="Name">Display name, e.g. "The Dead Hand Collection", "Glove Case".</param>
|
|
/// <param name="Type">"Collection" or "Container".</param>
|
|
public sealed record CatalogSource(string Id, string Name, string Type);
|