Ejemplo n.º 1
0
    public void EquipItem(GameObject equipItem, EquipSlots slot)
    {
        EventBox ev        = gameObject.GetComponent <EventBox> ();
        ItemInfo it        = equipItem.GetComponent <ItemInfo> ();
        int      slotIndex = (int)slot;

        slots [slotIndex].equippedItem       = equipItem;
        equipNode.children [slotIndex].title = slots [slotIndex].title + it.itemName;
        ev.AddMessage("Equipped the " + it.itemName + " to " + slot.ToString());
    }