SetWeaponRefModFlags

From GECK
Jump to: navigation, search


A function added by the JIP NVSE Plugin.

Description

Sets the bit-mask representing the calling weapon's currently installed weapon-mods. Unlike SetEquippedWeaponModFlags, this function is called on an inventory reference. The calling weapon reference does not have to be equipped.

Syntax

[help]
(success:0/1) reference.SetWeaponRefModFlags newFlags:int

Weapon Mod Flags

1	Weapon Mod #1
2	Weapon Mod #2
4	Weapon Mod #3

Example

rItemRef.SetWeaponRefModFlags 5

This will enable mods #1 and #3 (1 + 4).

Notes

  • Setting the flags to 0 on a weapon without any possible mods results in a bugged display. Unverified
  • Note that using this function to apply a durability altering weapon mod will not set the weapon's durability correctly afterwards. Unverified

See Also