Use typed runtime item category tokens
This commit is contained in:
parent
2a871e4cfb
commit
301b1251b1
9 changed files with 34 additions and 21 deletions
|
|
@ -227,7 +227,7 @@ public class ItemManager
|
|||
throw new NullReferenceException("Attempted to create crafted item instance using missing typed item data!");
|
||||
}
|
||||
|
||||
if (string.Equals(item.Category, nameof(ConsumableItemData), StringComparison.Ordinal))
|
||||
if (string.Equals(item.Category, AetheriaRuntimeItemCategories.Consumable, StringComparison.Ordinal))
|
||||
{
|
||||
return new ConsumableItem
|
||||
{
|
||||
|
|
@ -292,7 +292,7 @@ public class ItemManager
|
|||
private static bool IsEquippable(AetheriaRuntimeCatalogItem item)
|
||||
{
|
||||
return !string.IsNullOrWhiteSpace(item?.HardpointType) ||
|
||||
string.Equals(item?.Category, nameof(HullData), StringComparison.Ordinal);
|
||||
string.Equals(item?.Category, AetheriaRuntimeItemCategories.Hull, StringComparison.Ordinal);
|
||||
}
|
||||
|
||||
public (RarityTier tier, int upgrades) GetTier(CraftedItemInstance item)
|
||||
|
|
|
|||
Loading…
Reference in a new issue