Object Affects

Between zero and two "affects" may be set on an item. The affects could for example modify a characters strength, height etc. The affect only goes into effect when the character wears, wields or holds the item. The affect is removed when the character removes the items.

APPLY_NONE 0 DO NOT USE
APPLY_STR 1 Replaced (41)
APPLY_DEX 2 Replaced (42)
APPLY_INT 3 Replaced (43)
APPLY_WIS 4 Replaced (44)
APPLY_CON 5 Replaced (45)
APPLY_SEX 6 DO NOT USE
APPLY_CLASS 7 DO NOT USE
APPLY_LEVEL 8 DO NOT USE
APPLY_AGE 9
APPLY_CHAR_WEIGHT 10
APPLY_CHAR_HEIGHT 11
APPLY_MANA 12
APPLY_HIT 13 Adds hitpoints.
APPLY_MOVE 14 Adds move points
APPLY_GOLD 15 DO NOT USE
APPLY_EXP 16 DO NOT USE
APPLY_AC 17 Negative value is beneficial.
APPLY_HITROLL 18
APPLY_DAMROLL 19
APPLY_SAVING_PARA 20
APPLY_SAVING_ROD 21
APPLY_SAVING_PETRI 22
APPLY_SAVING_BREATH 23
APPLY_SAVING_SPELL 24
APPLY_FIRE_PROT 25 Just use PFF - Protection from Fire
APPLY_AGILITY 26 Replaced (46)
APPLY_POWER 27 Replaced (47)
APPLY_CHARISMA 28 Replaced (48)
APPLY_KARMA 29 Replaced (49) - Not displayed to player
APPLY_LUCK 30 Replaced (50) - Not displayed to player
APPLY_STR_MAX 31
APPLY_DEX_MAX 32
APPLY_INT_MAX 33
APPLY_WIS_MAX 34
APPLY_CON_MAX 35
APPLY_AGI_MAX 36
APPLY_POW_MAX 37
APPLY_CHA_MAX 38
APPLY_KARMA_MAX 39
APPLY_LUCK_MAX 40
APPLY_STR_RACE 41 these 10 override the racial stat_factor
APPLY_DEX_RACE 42 so that setting APPLY_STR_RACE for ogre will,
APPLY_INT_RACE 43 for example, give you gauntlets of ogre strength.
APPLY_WIS_RACE 44 Before using these, say to yourself, 'Are my
APPLY_CON_RACE 45 lungs safe?' The race numbers are:
APPLY_AGI_RACE 46
APPLY_POW_RACE 47 1 human, 2 barb, 3 drow, 4 elf, 5 dorf
APPLY_CHA_RACE 48 6 duergar, 7 halfling, 8 gnome, 9 ogre
APPLY_KARMA_RACE 49 10 troll, 11 halfelf, 12 squid, 13 yuanti
APPLY_LUCK_RACE 50 14 lich
APPLY_MAGIC_RESIST 51 Maximum total MR is 10%
APPLY_TRUE_STAT_STR 53
APPLY_TRUE_STAT_DEX 54 These 10 Will apply the actual number specified to the indicated stat.
APPLY_TRUE_STAT_AGI 55 the indicated stat, so "A 53 1" would apply one to the wearer's
APPLY_TRUE_STAT_CON 56 strength. ***I would prefer these be used from now on rather than
APPLY_TRUE_STAT_POW 57 the weird old ones that used the multiplier***
APPLY_TRUE_STAT_INT 58
APPLY_TRUE_STAT_WIS 59
APPLY_TRUE_STAT_CHA 60
APPLY_TRUE_STAT_LUC 61
APPLY_TRUE_STAT_CHA 62
SPELL_FOCUS_INVOCATION 63
SPELL_FOCUS_ILLUSION 64
SPELL_FOCUS_HEALING 65
SPELL_FOCUS_SUMMONING 66
SPELL_FOCUS_PROTECTION 67
SPELL_FOCUS_NECROMANCY 68
SPELL_FOCUS_ENCHANT 69
SPELL_FOCUS_SPIRIT 70
SPELL_FOCUS_NATURE 71
SPELL_FOCUS_ELEMENTAL 72

Modifier

The modifier is added to the APPLY_XXX ability of the character when he uses an item, and is subtracted when he stops using it. Take great care when using this. This is an example of an item of improve strength and armor class. Example:

A
1 2
A
17 -2

For normal stat adjustments (not max_stat), multiply the affect modifier by 4.5 round down. Thus A 1 2 is +9 strength, and A 2 3 is +13 dexterity.