-
assigned issue to
- edited description
[#modding] [Moddability] `BodyPart`s should fire the `"QuerySlotList"` event on their `Defa...
Marked for crossposting by: Noelle Lavenza (transgendeer)
Message (jump):
<Noelle Lavenza (transgendeer)> [Moddability]
BodyPart
s should fire the"QuerySlotList"
event on theirDefaultBehavior
, so that natural weapons can prevent equipping certain items without having to add a 0/0 Armor part. This would allow them to selectively allow/restrict equipping certain items. This could probably just be achieved by removing the Parts loop andreturn true;
at the end of theE.ID == "QuerySlotList"
block, which would lead to it being fired on equipped items, cybernetics, default behaviors, and other body parts.
Comments (3)
-
repo owner -
- changed status to open
-
- changed status to resolved
That's not how QuerySlotList works; it is never routed to any Equipped or Cybernetics object, rather it results in the minevent QueryEquippableListEvent being checked repeatedly on the object to be equipped. Equipped and Cybernetics items have the opportunity to deny the slot via CanBeUnequipped.
Next update will have an event you can use:
The QueryItemList event now gives DefaultBehavior objects the opportunity to prevent usage of their body part via the event CanEquipOverDefaultBehavior (parameters Object, the object to be equipped, Subject, the object it is potentially to be equippped on, and Part, the BodyPart being examined); returning false will prevent the object from being equipped in that slot.
- Log in to comment