Skip to main content

ChangedAttachments

Gets called when player has changed weapon attachments.

Start a script section

!-- OnEvent ChangedAttachments
-- require @evPlayer *evFirearmItem $evOldAttachments $evNewAttachments

# Add your instructions here
  • Group: PlayerEvents
  • Cancellable: No
  • Event data: PlayerChangedAttachmentsEventArgs

Injected variables

VariableTypeDescription
@evPlayerplayer valueGets the player that invoked the event.
*evFirearmItemreference to FirearmItem objectThe weapon that is involved in the event.
$evOldAttachmentsnumber valueGets previous attachments code.
$evNewAttachmentsnumber valueGets the new attachments code.