예제 #1
0
    public void RemoveWearable(WearableItem wearableItem)
    {
        if (wearableItem == null)
        {
            return;
        }

        if (!selectorsByCategory.ContainsKey(wearableItem.category))
        {
            Debug.LogError($"Category couldn't find selector for category: {wearableItem.category} ");
            return;
        }

        selectorsByCategory[wearableItem.category].RemoveItemToggle(wearableItem.id);
        if (wearableItem.IsCollectible())
        {
            collectiblesItemSelector.RemoveItemToggle(wearableItem.id);
        }
    }