mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-17 03:08:26 +00:00
[Quest API] Add Augment Slot support to does_augment_fit (#2813)
* [Quest API] Add Augment Slot support to does_augment_fit # Notes - Allows you to check if the supplied augment ID fits in the specified augment slot of the item instance provided. * Update item_instance.cpp
This commit is contained in:
+8
-1
@@ -3969,7 +3969,7 @@ bool QuestManager::DoAugmentSlotsMatch(uint32 item_one, uint32 item_two)
|
||||
return true;
|
||||
}
|
||||
|
||||
int8 QuestManager::DoesAugmentFit(EQ::ItemInstance* inst, uint32 augment_id)
|
||||
int8 QuestManager::DoesAugmentFit(EQ::ItemInstance* inst, uint32 augment_id, uint8 augment_slot)
|
||||
{
|
||||
if (!inst) {
|
||||
return INVALID_INDEX;
|
||||
@@ -3980,5 +3980,12 @@ int8 QuestManager::DoesAugmentFit(EQ::ItemInstance* inst, uint32 augment_id)
|
||||
return INVALID_INDEX;
|
||||
}
|
||||
|
||||
if (
|
||||
augment_slot != 255 &&
|
||||
!inst->IsAugmentSlotAvailable(aug_inst->AugType, augment_slot)
|
||||
) {
|
||||
return INVALID_INDEX;
|
||||
}
|
||||
|
||||
return inst->AvailableAugmentSlot(aug_inst->AugType);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user