IPGetWeaponEnhancementBonus
From NWN Lexicon
Jump to navigationJump to search
IPGetWeaponEnhancementBonus(object, int)
Returns a weapon's enhancement bonus.
int IPGetWeaponEnhancementBonus(
object oWeapon,
ITEM_PROPERTY_ENHANCEMENT_BONUS
);
Parameters
oWeapon
Weapon to get enhancement bonus from.
nEnhancementBonusType
See remarks. (Default: ITEM_PROPERTY_ENHANCEMENT_BONUS )
Description
Returns the current enhancement bonus of a weapon (+1 to +20), 0 if there is no enhancement bonus. You can test for a specific type of enhancement bonus by passing the appropritate ITEM_PROPERTY_ENHANCEMENT_BONUS_* constant into nEnhancementBonusType
Remarks
The following values are valid for nEnhancementBonusType:
ITEM_PROPERTY_ENHANCEMENT_BONUS
ITEM_PROPERTY_ENHANCEMENT_BONUS_VS_ALIGNMENT_GROUP
ITEM_PROPERTY_ENHANCEMENT_BONUS_VS_RACIAL_GROUP
ITEM_PROPERTY_ENHANCEMENT_BONUS_VS_SPECIFIC_ALIGNEMENT
Requirements
#include " x2_inc_itemprop "
Version
1.61
See Also
| constants: |
author: Lilac Soul