mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-02-22 12:39:59 +00:00
Don't pass obsolete slot parameter to cast
This commit is contained in:
parent
773d78192c
commit
8f10c8f84a
@ -3062,17 +3062,7 @@ namespace MWWorld
|
|||||||
if (inv.getSelectedEnchantItem() != inv.end())
|
if (inv.getSelectedEnchantItem() != inv.end())
|
||||||
{
|
{
|
||||||
const auto& itemPtr = *inv.getSelectedEnchantItem();
|
const auto& itemPtr = *inv.getSelectedEnchantItem();
|
||||||
auto [slots, _] = itemPtr.getClass().getEquipmentSlots(itemPtr);
|
cast.cast(itemPtr);
|
||||||
int slot = 0;
|
|
||||||
for (std::size_t i = 0; i < slots.size(); ++i)
|
|
||||||
{
|
|
||||||
if (inv.getSlot(slots[i]) == inv.getSelectedEnchantItem())
|
|
||||||
{
|
|
||||||
slot = slots[i];
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
cast.cast(itemPtr, slot);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user