GetWeaponBase

From GECK
Jump to: navigation, search


A function added by the pp NVSE Plugin.

Description

Returns the true baseform of a weapon. Useful for weapon base forms that have multiple Instances.

Syntax

[help]
(form) GetWeaponBase Weapon:ref

Example

let rWeap := Player.GetEquippedWeaponRef           ;Player is using a 9mm pistol with a fire rate modifier on it.
if IsWeaponInstance rWeap
   let rWeapInstance := rWeap.GBO                  ;Returns the baseform with the fire rate modifier.
   let rWeapBase := GetWeaponBase rWeapInstance    ;Returns the unmodified baseform WeapNV9mmPistol
endif
let rWeap := Player.GetEquippedWeaponRef       ;Player is using a 10mm pistol
let rWeapBase := GWB rWeap                     ;Returns Weap10mmPistol

See Also