Index  •  2DA  •  Effects  •  File Formats  •  Actions  •  Identifiers  •  Triggers  •  Appendices  •  Site Info  •  Legal

Opcodes


#0 (0x000) Stat: AC vs. Damage Type Modifier [0]
Parameter #1: AC Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'AC Modifier' field to the category specified by the 'Type' field.

Known values for 'Type' are:
0   All
1   Crushing
2   Missile
4   Piercing
8   Slashing
16  Base AC setting (sets the targets AC to the value specified by the 'AC Modifier' field -1. If the targets AC is already 'AC Modifier' or below, this effect will do nothing).



#1 (0x001) Stat: Attacks Per Round Modifier [1]
Parameter #1: Key Modifier
Parameter #2: Type
Description:
Alters a characters Attacks per Round, by changing the Key by the modifier value specified by the 'Key Value' field, in the style specified by 'Type' field.

Key     Attacks Per Round
0        0
1        1
2        2
3        3
4        4
5+      5

Known values for 'Type' are:
0   Cumulative Modifier -> Key = Key + 'Key Modifier' value
1   Flat Value Modifier -> Key = 'Key Modifier' value
2   Percentage Modifier -> Key = (Key * 'Key Modifier' value) / 100

Note: When this opcode is stacked, the values of the Key Modifier are stacked, not the number of attacks.



#2 (0x002) Cure: Sleep [2]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the state_sleeping flag from the targeted creature(s).
This effect ignores durations attributed to it.

N.B. Does not remove the state_helpless flag.



#3 (0x003) State: Berserking [3]
Parameter #1: Irrelevant
Parameter #2: Type
Description:
Applies the berserk effect to the targeted creature(s), as specifed by the 'Type' field.
Target will uncontrollably attack enemies if any are in view, and will occasionally attack neutral creatures.

Known values for 'Type' are:
0   Default
1   Always Active
2   Blood Rage



#4 (0x004) Cure: Berserking [4]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the state_beserk flag from the targeted creature(s).
This effect ignores durations attributed to it.



#5 (0x005) Charm: Charm Specific Creature [5]
Parameter #1: General Type
Parameter #2: Charm Type
Description:
Charms the targeted creature(s) according to value in the 'Charm Type' field, if the target is matched by the value in the 'General Type' field. Values for 'General Type' are from General.ids.

Known values for 'Charm Type' are:
0    Charmed (Target neutral after effect ends)
1    Charmed (Target hostile after effect ends)
2    Dire charmed (Target neutral after effect ends)
3    Dire charmed (Target hostile after effect ends)
4    Controlled by Cleric
5    Target is hostile



#6 (0x006) Stat: Charisma Modifier [6]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Charisma = Charisma + 'Statistic Modifier' value
1   Flat Value Modifier -> Charisma = 'Statistic Modifier' value
2   Percentage Modifier -> Charisma = (Charisma * 'Statistic Modifier' value) / 100


Negative values for 'Statistic Modifier' act as follows for the 'Type' modes:
0   Charisma = Charisma - 'Statistic Modifier' value
1   Charisma = 25
2   Charisma = 25



#7 (0x007) Colour: Set character colours by Palette [7]
Parameter #1: Gradient Number
Parameter #2: Location
Description:
Alters the colour of the area specified by the 'Location' field, to the colour gradient specified by the 'Gradient Number' field.

Known values for 'Location' are:
0   Body Metal
1   Body User 2
2   Body User 1
3   Body Skin
4   Body Leather
5   Body Armor
6   Body Hair
16  Weapon Metal
18  Weapon User 1
19  Weapon User 2
20  Weapon Leather
21  Weapon Armor
32  Shield Metal
33  Shield User 2
34  Shield User 1
36  Shield Leather
37  Shield Armor
48  Helmet Metal
49  Helmet User 2
50  Helmet User 1
52  Helmet Leather
53  Helmet Armor
255 Whole Body



#8 (0x008) Colour: Change by RGB [8]
Parameter #1: RGB Colour
Parameter #2: Location
Description:
Alters the colour of the area specified by the 'Location' field, to the colour specified by the 'RGB Colour' field.

The 'RGB Colour' field is handled as follows:
Second byte = Red (0-255)
Third byte     = Green (0-255)
Fourth byte   = Blue (0-255)

Known values for 'Location' are:
0   Body metal
1   Body User 2
2   Body User 1
3   Body Skin
4   Body Leather
5   Body Armor
6   Body Hair
16  Weapon Metal
18  Weapon User 1
19  Weapon User 2
20  Weapon Leather
21  Weapon Armor
32  Shield Metal
33  Shield User 2
34  Shield User 1
36  Shield Leather
37  Shield Armor
48  Helmet Metal
49  Helmet User 2
50  Helmet User 1
52  Helmet Leather
53  Helmet Armor
255 Whole Body



#9 (0x009) Colour: Glow Pulse [9]
Parameter #1: RGB Colour
Parameter #2: Location and Speed
Description:
Pulses the area specified by the 'Location and Speed' field, at the rate specified by the 'Location and Speed' field, with the colour specified by the 'RGB Colour' field. If the colour values are all set to 0, the glow effect only occurs if the creature is in darkness; outside at night, inside a building, or standing in shadows.

The 'RGB Colour' field is handled as follows:
Second byte = Red (0-255)
Third byte     = Green (0-255)
Fourth byte   = Blue (0-255)

The 'Location and Speed' field is handled as follows:
First byte = Location
Third byte = Speed

A speed of 0 does not pulsate. A speed of 1 is fastest, and a speed of 255 is slowest.

Known values for 'Location' are:
0   Body metal
1   Body User 2
2   Body User 1
3   Body Skin
4   Body Leather
5   Body Armor
6   Body Hair
16  Weapon Metal
18  Weapon User 1
19  Weapon User 2
20  Weapon Leather
21  Weapon Armor
32  Shield Metal
33  Shield User 2
34  Shield User 1
36  Shield Leather
37  Shield Armor
48  Helmet Metal
49  Helmet User 2
50  Helmet User 1
52  Helmet Leather
53  Helmet Armor
255 Whole Body



#10 (0x00A) Stat: Constitution Modifier [10]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Consitution = Consitution + 'Statistic Modifier' value
1   Flat Value Modifier -> Consitution = 'Statistic Modifier' value
2   Percentage Modifier -> Consitution = (Consitution * 'Statistic Modifier' value) / 100


Negative values for 'Statistic Modifier' act as follows for the 'Type' modes:
0   Consitution = Consitution - 'Statistic Modifier' value
1   Consitution = 25
2   Consitution = 25



#11 (0x00B) Cure: Poison [11]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the poison effect from the targeted creatre(s).
This effect ignores durations attributed to it.



#12 (0x00C) HP: Damage [12]
Parameter #1: Damage Amount
Parameter #2: Type
Description:
Damages the target by the value specified by the 'Damage Amount' field, with the damage type specified by the 'Type' field.

Known values for 'Type' are:
0           Crushing
1           Crushing Set to Value
2           Crushing Set to Percentage
65536       Acid
65537       Acid Set to Value
65538       Acid Set to Percentage
131072      Cold
131073      Cold Set to Value
131074      Cold Set to Percentage
262144      Electricity
262145      Electricity Set to Value
262146      Electricity Set to Percentage
524288      Fire
524289      Fire Set to Value
524290      Fire Set to Percentage
1048576     Piercing
1048577     Piercing Set to Value
1048578     Piercing Set to Percentage
2097152     Poison
2097153     Poison Set to Value
2097154     Poison Set to Percentage
4194304     Magic
4194305     Magic Set to Value
4194306     Magic Set to Percentage
8388608     Missile
8388609     Missile Set to Value
8388610     Missile Set to Percentage
16777216    Slashing
16777217    Slashing Set to Value
16777218    Slashing Set to Percentage
33554432    Magic Fire
33554433    Magic Fire Set to Value
33554434    Magic Fire Set to Percentage
67108864    Magic Cold
67108865    Magic Cold Set to Value
67108866    Magic Cold Set to Value
134217728   Stunning
134217729   Stunning Set to Value
134217730   Stunning Set to Percentage
268435456   Soul Eater
268435457   Soul Eater Set to Value
268435458   Soul Eater Set to Percentage
1073741824  Disease
1073741825  Disease Set to Value
1073741825  Disease Set to Percentage

The Dice values can be used to inflict varying damage amounts - e.g. 2d6 would do 2-12 damage (Damage type is still specified by the 'Type' value).

NB. 'Stunning' damage does not stun the target. Stunning damage cannot kill a creature, creatures are reduced to 1 HP and are knocked unconscious.
NB. Using 'Magic Fire' as a damage type will result the game to crash if the damage kills the target.
NB. If 'Damage Amount' and the Dice values are both non-zero, the total damage inflicted is: 'Damage Amount' + Dice value.
NB. 'Damage Amount' can be positive or negative (though the damage sound will play in either case).



#13 (0x00D) Death: Instant Death [13]
Parameter #1: Text Notification
Parameter #2: Death Type
Description:
Instantly kills the targeted creature(s), in the style specified by the 'Death Type' value.

Known values for 'Text Notification' are:
0   Show death message
1   Don't show death message

Known values for 'Death Type' are:
0   Acid death
1   Burning death
2   Crushed death
4   Normal death
8   Exploding death
16  Stoned death
32  Freezing death
512  Permanent death
1024 Destruction death



#14 (0x00E) Graphics: Defrost [14]
Parameter #1: Undefined
Parameter #2: Undefined
Description:
Temporarily removes the colouring indicating frozen_death from the targeted creature(s), but does not remove the frozen_death state itself.



#15 (0x00F) Stat: Dexterity Modifier [15]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Dexterity = Dexterity + 'Statistic Modifier' value
1   Flat Value Modifier -> Dexterity = 'Statistic Modifier' value
2   Percentage Modifier -> Dexterity = (Dexterity * 'Statistic Modifier' value) / 100
3   Cat's Grace Spell ('Statistic Modifier' should be set to 0)

Negative values for 'Statistic Modifier' act as follows for the 'Type' modes:
0   Dexterity = Dexterity - 'Statistic Modifier' value
1   Dexterity = 25
2   Dexterity = 25



#16 (0x010) State: Haste [16]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the Haste effect to the targeted creature(s).
This effect will cancel out the slow opcode.



#17 (0x011) HP: Current HP Modifier [17]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> HP = HP + 'Statistic Modifier' value
1   Flat Value Modifier -> HP = 'Statistic Modifier' value
2   Percentage Modifier -> HP = (HP * 'Statistic Modifier' value) / 100

NB. If 'Statistic Modifier' and the Dice values are both non-zero, the total HP change is: 'Statistic Modifier' + Dice value.
NB. 'Statistic Modifier' can be positive or negative.



#18 (0x012) HP: Maximum HP Modifier [18]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> HP = HP + 'Statistic Modifier' value
1   Flat Value Modifier -> HP = 'Statistic Modifier' value
2   Percentage Modifier -> HP = (HP * 'Statistic Modifier' value) / 100

3   As 0 (does not affect current HP)
4   As 1 (does not affect current HP)
5   As 2 (does not affect current HP)

NB. If 'Statistic Modifier' and the Dice values are both non-zero, the total HP change is: 'Statistic Modifier' + Dice value.
NB. 'Statistic Modifier' can be positive or negative.



#19 (0x013) Stat: Intelligence Modifier [19]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Intelligence = Intelligence + 'Statistic Modifier' value
1   Flat Value Modifier -> Intelligence = 'Statistic Modifier' value
2   Percentage Modifier -> Intelligence = (Intelligence * 'Statistic Modifier' value) / 100

'Statistic Modifier' can be positive or negative.



#20 (0x014) State: Invisibility [20]
Parameter #1: Irrelevant
Parameter #2: Type
Description:
Applies the invisibility effect, in the style specified by the 'Type' value.

Known values for 'Type' are :
0   Normal Invisibility   -> affected creature makes the first attack with +4
1   Improved Invisibility -> affected creature stays invisible after attack
2   Toggle Invisibility   -> affected creature invisibility state toggles when executing an action

Improved Invisibility does not provide saving throw bonuses.
Improved Invisibility lingers after the duration is spent and works very permanent if used as a While Equipped effect.



#21 (0x015) Stat: Lore Modifier [21]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Lore = Lore + 'Statistic Modifier' value
1   Flat Value Modifier -> Lore = 'Statistic Modifier' value
2   Percentage Modifier -> Lore = (Lore * 'Statistic Modifier' value) / 100

'Statistic Modifier' can be positive or negative.
NB. This effect does not work with Timing Mode 1.



#22 (0x016) Stat: Luck Modifier [22]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field. The effect does not set STATE_LUCK.

Known values for 'Type' are:
0   Cumulative Modifier -> Luck = Luck + 'Statistic Modifier' value
1   Lucky Streak
2   Fortunes Favorite (perfect rolls)



#23 (0x017) Stat: Morale Modifier [23]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Morale = Morale + 'Statistic Modifier' value
1   Flat Value Modifier -> Morale = 'Statistic Modifier' value
2   Percentage Modifier -> Morale = (Morale * 'Statistic Modifier' value) / 100



#24 (0x018) State: Horror [24]
Parameter #1: Irrelevant
Parameter #2: Type
Description:
Applies the horror effect to the targeted creature(s), in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Normal
1   Harpy Wail



#25 (0x019) State: Poison [25]
Parameter #1: Damage Amount
Parameter #2: Type
Description:
Damages the target by the 'Damage Amount' value, in the style specified by the 'Type' field.

Known values for 'Type' are:
0  
1   Inflict 'Damage Amount' per second halting at value controlled by 'Damage Amount' (pattern unknown)
2   Inflict 'Damage Amount' per second
3   Inflict  1 Damage per 'Damage Amount' seconds
4   Inflict 'Damage Amount' per round
5   Crash
6   Snakebite
8   Envenomed Weapon



#26 (0x01A) Item: Remove Curse [26]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes cursed items from the targeted creature(s).



#27 (0x01B) Stat: Acid Resistance Modifier [27]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Resistance = Resistance + 'Statistic Modifier' value
1   Flat Value Modifier -> Resistance = 'Statistic Modifier' value
2   Percentage Modifier -> Resistance = (Resistance * 'Statistic Modifier' value) / 100

'Statistic Modifier' can be positive or negative.



#28 (0x01C) Stat: Cold Resistance Modifier [28]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Resistance = Resistance + 'Statistic Modifier' value
1   Flat Value Modifier -> Resistance = 'Statistic Modifier' value
2   Percentage Modifier -> Resistance = (Resistance * 'Statistic Modifier' value) / 100

'Statistic Modifier' can be positive or negative.



#29 (0x01D) Stat: Electricity Resistance Modifier [29]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Resistance = Resistance + 'Statistic Modifier' value
1   Flat Value Modifier -> Resistance = 'Statistic Modifier' value
2   Percentage Modifier -> Resistance = (Resistance * 'Statistic Modifier' value) / 100

'Statistic Modifier' can be positive or negative.



#30 (0x01E) Stat: Fire Resistance Modifier [30]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Resistance = Resistance + 'Statistic Modifier' value
1   Flat Value Modifier -> Resistance = 'Statistic Modifier' value
2   Percentage Modifier -> Resistance = (Resistance * 'Statistic Modifier' value) / 100

'Statistic Modifier' can be positive or negative.



#31 (0x01F) Stat: Magic Damage Resistance Modifier [31]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Resistance = Resistance + 'Statistic Modifier' value
1   Flat Value Modifier -> Resistance = 'Statistic Modifier' value
2   Percentage Modifier -> Resistance = (Resistance * 'Statistic Modifier' value) / 100

'Statistic Modifier' can be positive or negative.



#32 (0x020) Cure: Death (Raise Dead) [32]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Raises the targeted creature(s) from the dead.
This effect ignores durations attributed to it.



#33 (0x021) Stat: Save vs. Death Modifier [33]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Save = Save + 'Statistic Modifier' value
1   Flat Value Modifier -> Save = 'Statistic Modifier' value
2   Percentage Modifier -> Save = (Save * 'Statistic Modifier' value) / 100

'Statistic Modifier' can be positive or negative.



#34 (0x022) Stat: Save vs. Wands Modifier [34]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Save = Save + 'Statistic Modifier' value
1   Flat Value Modifier -> Save = 'Statistic Modifier' value
2   Percentage Modifier -> Save = (Save * 'Statistic Modifier' value) / 100

'Statistic Modifier' can be positive or negative.



#35 (0x023) Stat: Save vs. Petrification/Polymorph Modifier [35]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Save = Save + 'Statistic Modifier' value
1   Flat Value Modifier -> Save = 'Statistic Modifier' value
2   Percentage Modifier -> Save = (Save * 'Statistic Modifier' value) / 100

'Statistic Modifier' can be positive or negative.



#36 (0x024) Stat: Save vs. Breath Weapons Modifier [36]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Save = Save + 'Statistic Modifier' value
1   Flat Value Modifier -> Save = 'Statistic Modifier' value
2   Percentage Modifier -> Save = (Save * 'Statistic Modifier' value) / 100

'Statistic Modifier' can be positive or negative.



#37 (0x025) Stat: Save vs. Spells Modifier [37]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Save = Save + 'Statistic Modifier' value
1   Flat Value Modifier -> Save = 'Statistic Modifier' value
2   Percentage Modifier -> Save = (Save * 'Statistic Modifier' value) / 100

'Statistic Modifier' can be positive or negative.



#38 (0x026) State: Silence [38]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the silence effect to the targeted creature(s).



#39 (0x027) State: Unconsciousness [39]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the unconsciousness effect to the targeted creature(s).

N.B. A permanent timing mode will set the state_helpless flag.



#40 (0x028) State: Slow [40]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the slow effect to the targeted creature(s).
This effect will cancel out the haste opcode.

N.B. This effect doubles the casting time of all spells.



#41 (0x029) Graphics: Sparkle [41]
Parameter #1: Colour
Parameter #2: Type
Description:
Displays the sparkle effect specified by the 'Type' field, in the colour specified by the 'Colour' field.

Known values for 'Colour' are:
0   Crash
1   No effect / Black
2   White / White -> Blue
3   Purple -> White / Purple -> White
4  
..  White
12
13  Crash

Known values for 'Type' are:
1   Sparkle Puff
2   No effect?
3   Sparkle Shower



#42 (0x02A) Spell: Wizard Spell Slots Modifier [42]
Parameter #1: Slot Amount Modifier
Parameter #2: Spell Level
Description:
Alters the number of wizard spell slots available to the targeted creature(s), as specified by the 'Slot Amount Modifier' field, at the level specified by the 'Spell Level' field.

Known values for 'Spell Level' are:
0   Double spells
1   Level 1
1   Level 1
2   Level 2
4   Level 3
8   Level 4
16  Level 5
32  Level 6
64  Level 7
128 Level 8
256 Level 9
512 Double spells

For a 'Spell Level' of 0, the amount of spell slots is doubled for the level specified by the 'Slot Amount Modifier' value and all levels below. For a 'Spell Level' of 512, the amount of spell slots is doubled for the level(s) specified by the 'Slot Amount Modifier' field. The target creature(s) must have at least 1 slot at the selected level to have their slot count changed. If the resultant slot count is negative, the creature is given 12 slots.

'Statistic Modifier' can be positive or negative.



#43 (0x02B) Cure: Stone to Flesh [43]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Changes the targeted creature(s) from stone to flesh.



#44 (0x02C) Stat: Strength Modifier [44]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Strength = Strength + 'Statistic Modifier' value
1   Flat Value Modifier -> Strength = 'Statistic Modifier' value
2   Percentage Modifier -> Strength = (Charisma * 'Statistic Modifier' value) / 100
3   Strength Spell ('Statistic Modifier' should be set to 0)

Negative values for 'Statistic Modifier' act as follows for the 'Type' modes:
0   Strength = Strength - 'Statistic Modifier' value
1   Strength = 25
2   Strength = 25



#45 (0x02D) State: Stun [45]
Parameter #1: Irrelevant
Parameter #2: Type
Description:
Stuns the targeted creature(s).

Known values for 'Type' are:
0   Normal
1   Unstun on Damage
2   Power Word Stun



#46 (0x02E) Cure: Stun (Unstun) [46]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Unstuns the targeted creature(s) (opcode #45).
This effect ignores durations attributed to it.



#47 (0x02F) Cure: Invisibility [47]
Parameter #1: Undefined
Parameter #2: Undefined
Description:
Removes the invisibility effect from the targeted creature(s).



#48 (0x030) Cure: Silence (Vocalize) [48]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the silence effect and the silenced state from the targeted creature(s).
This effect ignores durations attributed to it.



#49 (0x031) Stat: Wisdom Modifier [49]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Wisdom = Wisdom + 'Statistic Modifier' value
1   Flat Value Modifier -> Wisdom = 'Statistic Modifier' value
2   Percentage Modifier -> Wisdom = (Wisdom * 'Statistic Modifier' value) / 100

Negative values for 'Statistic Modifier' act as follows for the 'Type' modes:
0   Wisdom = Wisdom - 'Statistic Modifier' value
1   Wisdom = 25
2   Wisdom = 25



#50 (0x032) Colour: Glow by RGB (Brief) [50]
Parameter #1: RGB Colour
Parameter #2: Speed
Description:
The targeted creature(s) entire animation glows the colour specified by the 'RGB Colour' field, at the speed specified by the (3rd byte of the) 'Speed' field.

The 'RGB Colour' field is handled as follows:
Second byte = Red (0-255)
Third byte  = Green (0-255)
Fourth byte = Blue (0-255)

The 'Speed' field is handled as follows:
Third byte  = Speed (0-255)

A speed of 0 does not pulsate. A speed of 1 is fastest, and a speed of 255 is slowest.

Known values for 'Location and Speed' are:
0   Body metal
1   Body User 2
2   Body User 1
3   Body Skin
4   Body Leather
5   Body Armor
6   Body Hair
16  Weapon Metal
18  Weapon User 1
19  Weapon User 2
20  Weapon Leather
21  Weapon Armor
32  Shield Metal
33  Shield User 2
34  Shield User 1
36  Shield Leather
37  Shield Armor
48  Helmet Metal
49  Helmet User 2
50  Helmet User 1
52  Helmet Leather
53  Helmet Armor
255 Whole Body



#51 (0x033) Colour: Strong/Dark by RGB [51]
Parameter #1: RGB Colour
Parameter #2: Location
Description:
Alters the colour of the area specified by the 'Location and Speed' field, to the colour specified by the 'RGB Colour' field.

The 'RGB Colour' field is handled as follows:
Second byte = Red (0-255)
Third byte  = Green (0-255)
Fourth byte = Blue (0-255)

Known values for 'Location' are:
0   Body metal
1   Body User 2
2   Body User 1
3   Body Skin
4   Body Leather
5   Body Armor
6   Body Hair
16  Weapon Metal
18  Weapon User 1
19  Weapon User 2
20  Weapon Leather
21  Weapon Armor
32  Shield Metal
33  Shield User 2
34  Shield User 1
36  Shield Leather
37  Shield Armor
48  Helmet Metal
49  Helmet User 2
50  Helmet User 1
52  Helmet Leather
53  Helmet Armor
255 Whole Body



#52 (0x034) Colour: Very Bright by RGB [52]
Parameter #1: RGB Colour
Parameter #2: Location
Description:
Alters the colour of the area specified by the 'Location' field, to the colour specified by the 'RGB Colour' field.

The 'RGB Colour' field is handled as follows:
Second byte = Red (0-255)
Third byte  = Green (0-255)
Fourth byte = Blue (0-255)

Known values for 'Location' are:
0   Body metal
1   Body User 2
2   Body User 1
3   Body Skin
4   Body Leather
5   Body Armor
6   Body Hair
16  Weapon Metal
18  Weapon User 1
19  Weapon User 2
20  Weapon Leather
21  Weapon Armor
32  Shield Metal
33  Shield User 2
34  Shield User 1
36  Shield Leather
37  Shield Armor
48  Helmet Metal
49  Helmet User 2
50  Helmet User 1
52  Helmet Leather
53  Helmet Armor
255 Whole Body



#53 (0x035) Empty: [53]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
This opcode has no effect.



#54 (0x036) Stat: THAC0 Modifier [54]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> THAC0 = THAC0 + 'Statistic Modifier' value
1   Flat Value Modifier -> THAC0 = 'Statistic Modifier' value
2   Percentage Modifier -> THAC0 = (THAC0 * 'Statistic Modifier' value) / 100



#55 (0x037) Death: Kill Creature Type [55]
Parameter #1: IDS Entry
Parameter #2: IDS File
Description:
Kills the targeted creature(s) with HD less than those specified by the Dice values, if the target(s) match the IDS mask.

Known values for 'IDS File' are:
2   EA.ids
3   General.ids
4   Race.ids
5   Class.ids
6   Specific.ids
7   Gender.ids
8   Align.ids

'IDS Entry' is a value from the specified IDS file, indicating the specific creature type to affect.



#56 (0x038) Alignment: Invert [56]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Inverts the alignment of the targeted creature(s).



#57 (0x039) Alignment: Change [57]
Parameter #1: Irrelevant
Parameter #2: Alignment
Description:
Alters the alignment of the targeted creature(s) to the value specified by 'Alignment'.

Known values for 'Alignment' are:
00   None
17   Lawful Good
18   Lawful Neutral
19   Lawful Evil
33   Neutral Good
34   True Neutral
35   Neutral Evil
49   Chaotic Good
50   Chaotic Neutral
51   Chaotic Evil



#58 (0x03A) Cure: Dispellable Effects (Dispel Magic) [58]
Parameter #1: Level
Parameter #2: Type
Description:
Dispels magic from the targeted creature(s) (excepting magical weapons eg. Spirtual Hammer). Depending on the value of the 'Type' field, the 'Level' field can be used to set the level of the effect.

Known values for 'Type' are:
0   Always dispel
1   Use Caster Level
2   Use 'Level' field

With 'Type' of 1 or 2, the base chance of successfully dispelling is 50%. This chance is modified by the relative levels of the dispeller to the caster. Each level below gives a -10% chance, each level above gives a +5% chance. There is always a 1% chance of success or failure.



#59 (0x03B) Stat: Stealth Modifier [59]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Stealth = Stealth + 'Statistic Modifier' value
1   Flat Value Modifier -> Stealth = 'Statistic Modifier' value
2   Percentage Modifier -> Stealth = (Stealth * 'Statistic Modifier' value) / 100



#60 (0x03C) Stat: Miscast Magic [60]
Parameter #1: Percent Chance
Parameter #2: Type
Description:
The targeted creature(s) will fail to cast the type of spell specified by the 'Type' field, 'Percent Chance' percent of the time.

Known values for 'Type' are:
0   Mage Spells
1   Cleric Spells
2   Innate



#61 (0x03D) Crash [61]
Parameter #1: Undefined
Parameter #2: Undefined
Description:
This effect crashes the game.
This effect has previously been referenced as Alchemy.



#62 (0x03E) Spell: Priest Spell Slots Modifier [62]
Parameter #1: Slot Amount Modifier
Parameter #2: Spell Level
Description:
Alters the number of priest spell slots available to the targeted creature(s), as specified by the 'Slot Amount Modifier' field, at the level specified by the 'Spell Level' field.

Known values for 'Spell Level' are:
0   Double spells
1   Level 1
1   Level 1
2   Level 2
4   Level 3
8   Level 4
16  Level 5
32  Level 6
64  Level 7
512 Double spells

For a 'Spell Level' of 0, the amount of spell slots is doubled for the level specified by the 'Slot Amount Modifier' value and all levels below. For a 'Spell Level' of 512, the amount of spell slots is doubled for the level(s) specified by the 'Slot Amount Modifier' field. The target creature(s) must have at least 1 slot at the selected level to have their slot count changed. If the resultant slot count is negative, the creature is given 12 slots.

'Statistic Modifier' can be positive or negative.



#63 (0x03F) State: Infravision [63]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Gives the targeted creature(s) infravision.



#64 (0x040) State: Remove Infravision [64]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes infravision from the targeted creature(s).

NB. This will not remove racial infravision.



#65 (0x041) Overlay: Blur [65]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the blur effect to the targeted creature(s). Graphical displacement is affected by movement rate.



#66 (0x042) Graphics: Transparency Fade [66]
Parameter #1: Fade Amount
Parameter #2: Type
Description:
Fades the targeted creature(s) by the value in the amount specified by the 'Fade Amount' field.

Known values for 'Fade Amount' are:
1   Fully visible
..
255 Almost invisible

Known values for 'Type' are:
0   Default
1   Fade In
2   Fade Out



#67 (0x043) Summon: Creature Summoning [67]
Parameter #1: Unknown
Parameter #2: Control
Description:
Summons a creature, with EA set to the 'Control' field. The Resource key should be set to the filename of the creature to summon.

Known values for 'Control' are:
0    Match target (hostile if no target)
1    Match target (hostile if no target)  
2    As creature file
3    Match target (hostile if no target)
4    As creature file
5    Hostile to target
6    As creature file
8    As creature file
255  As creature file

If effect's target is set as 'Original Caster' then the 'Control' parameter covers 'Location' as well as control. In this case, nown values for 'Control' are:
2   = Summoned at location of target creature
4   = Summoned at location of caster
6   = Summoned at location of caster



#68 (0x044) Summon: Unsummon Creature [68]
Parameter #1: Text Notification
Parameter #2: Irrelevant
Description:
Unsummons a creature, with feedback controlled by 'Text Notification'.

Known values for 'Text Notification' are:
0   No text notification
1   Show text notification



#69 (0x045) Protection: From Detection (Non-Detection) [69]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the non-detection effect to the targeted creature(s).



#70 (0x046) Cure: Non-Detection [70]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the Non-Detection effect from the targeted creature(s).



#71 (0x047) IDS: Sex Change [71]
Parameter #1: Gender Modifier
Parameter #2: Type
Description:
Alters the gender of the targetted creature(s) to the value specified by the 'Gender.ids' field, in the style specified by the 'Type' value.

Known values for 'Type' are:
0 Reverse Gender
1 Flat Value Modifier -> Gender = 'Statistic Modifier' value (values from gender.ids)



#72 (0x048) IDS: Set IDS State [72]
Parameter #1: IDS Entry
Parameter #2: IDS File
Description:
Alters the IDS state of the targeted creature(s) specified by the 'IDS File' field, to the value specified by the 'IDS Entry' field.

Known values for 'IDS File' are:
0   EnemyAlly
1   General
2   Race
3   Class
4   Specific
5   Gender
6   Alignment



#73 (0x049) Damage Mod
Parameter #1: Damage Modifier
Parameter #2: Type
Description:
Inflicts a percentage extra damage (set by the 'Damage Modifier' parameter) of the type specified by the 'Type' parameter.

Known values for 'Type' are:
0  Standard
1  Fire
2  Cold
3  Electricity
4  Acid
5  Magic
6  Poison
7  Slashing
8  Piercing
9  Crushing
10 Missile

Note. 'Type' 0 causes a flat damage increase, rather than a percentage.



#74 (0x04A) State: Blindness [74]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the blindness effect to the targeted creature(s).



#75 (0x04B) Cure: Blindness [75]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the blindness effect from the targeted creature(s).



#76 (0x04C) State: Feeblemindedness [76]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the feeblemind effect to the targeted creature(s) - creatures are unselectable, immobile and do not respond to combat.
This effect ignores durations attributed to it.

NB. A creatures scripts do not while the creature is feebleminded.



#77 (0x04D) Cure: Feeblemindedness [77]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the feeblemind effect from the targeted creature(s).



#78 (0x04E) State: Disease [78]
Parameter #1: Damage
Parameter #2: Type
Description:
Set the Damage parameter as the amount of damage, and the Disease Type parameter as how the disease functions.

Known values for 'Type' are:
1   Hit Points per round
2   Hit Points per Second
3   Seconds per Hit Points
4   Strength Penalty
5   Dexterity Penalty
6   Constitution Penalty
7   Intelligence Penalty
8   Wisdom Penalty
9   Charisma Penalty
10  Slow Effect
11  Mold Touch
13  Contagion

'Damage' can be positive (penalty) or negative (bonus).

Permanent timing modes require a duration for this effect to work.
Note: Paladins are immune to this opcode.



#79 (0x04F) Cure: Disease [79]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the disease effect from the targeted creature(s).



#80 (0x050) State: Deafness [80]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the Deafness effect on the targeted creature(s) - creatures suffer an unknown percentage casting failure rate. This is cumulative with Miscast Magic.



#81 (0x051) Cure: Deafness [81]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Remove the deafness effect from the targeted creature(s).



#82 (0x052) Set AI Script [82]
Parameter #1: Irrelevant
Parameter #2: Type
Description:
Sets the script type specified by the 'Type' value to the contents of the resource key.

Known values for 'Type' are:
0   OVERRIDE
1   AREA
2   SPECIFICS
4   CLASS
5   RACE
6   GENERAL
7   DEFAULT

NB. This effect can unset scripts from a creature, which can break the game.



#83 (0x053) Protection: From Projectile Weapon [83]
Parameter #1: Irrelevant
Parameter #2: Type
Description:
Gives the targeted creature(s) immunity to the weapon type specified by the 'Type' value.

Known values for 'Type' are:
0   Instant
1   Arrow
2   Arrow Exploding
3   Arrow Flaming
4   Arrow Heavy*
5   Arrow (Non-Magical)
6   Axe
7   Axe Exploding
8   Axe Flaming
9   Axe Heavy*
10  Axe (Non-Magical)
11  Bolt
12  Bolt Exploding
13  Bolt Flaming
14  Bolt Heavy*
15  Bolt (Non-Magical)
16  Bullet
17  Bullet Exploding
18  Bullet Flaming
19  Bullet Heavy*
20  Bullet (Non-Magical)
26  Dagger*
27  Dagger Exploding
28  Dagger Flaming
29  Dagger Heavy
30  Dagger (Non-Magical)
31  Dart
32  Dart Exploding
33  Dart Flaming
34  Dart Heavy*
35  Dart (Non-Magical)
36  Magic Missile
37  Fireball
39  Lightning Bolt
41  Sleep
55  Spear
56  Spear Exploding
57  Spear Flaming
58  Spear Heaby
59  Spear (Non-Magical)
62  Web Travel
63  Web Ground
64  Gaze
65  Holy Might
66  Flame Strike
67  Magic Missile 1
68  Magic Missile 2
69  Magic Missile 3
70  Magic Missile 4
71  Magic Missile 5
72  Magic Missile 6
73  Magic Missile 7
74  Magic Missile 8
75  Magic Missile 9
76  Magic Missile 10
94  Cloud
95  Skull Trap
96  Colour Spray
97  Ice Storm
98  Fire Wall
99  Glyph
100 Grease
101 Flame Arrow Green
102 Flame Arrow Blue
103 Fireball Green
104 FireBall Blue
105 Potion
106 Potion Exploding
107 Acid Blob
108 Scorcher
109 Travel Door
186 Cloudkill
187 Flame Arrow Ice
188 Cow
189 Hold
190 Scorcher Ice
191 Acid Blob Mustard
192 Acid Blob Grey
193 Acid Blob Ochre
217 Icewind Magic Missile
313 Modenkainen's Force Missiles
345 Sekolah's Fire



#84 (0x054) Empty: [84]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
This opcode has no effect.



#85 (0x055) Empty: [85]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
This opcode has no effect.



#86 (0x056) Stat: Slashing Resistance Modifier [86]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Damage = Damage + 'Statistic Modifier' value
1   Flat Value Modifier -> Damage = 'Statistic Modifier' value
2   Percentage Modifier -> Damage = (Damage * 'Statistic Modifier' value) / 100



#87 (0x057) Stat: Crushing Resistance Modifier [87]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Damage = Damage + 'Statistic Modifier' value
1   Flat Value Modifier -> Damage = 'Statistic Modifier' value
2   Percentage Modifier -> Damage = (Damage * 'Statistic Modifier' value) / 100



#88 (0x058) Stat: Piercing Resistance Modifier [88]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Damage = Damage + 'Statistic Modifier' value
1   Flat Value Modifier -> Damage = 'Statistic Modifier' value
2   Percentage Modifier -> Damage = (Damage * 'Statistic Modifier' value) / 100



#89 (0x059) Stat: Missiles Resistance Modifier [89]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Damage = Damage + 'Statistic Modifier' value
1   Flat Value Modifier -> Damage = 'Statistic Modifier' value
2   Percentage Modifier -> Damage = (Damage * 'Statistic Modifier' value) / 100



#90 (0x05A) Stat: Open Locks Modifier [90]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Skill = Skill + 'Statistic Modifier' value
1   Flat Value Modifier -> Skill = 'Statistic Modifier' value
2   Percentage Modifier -> Skill = (Skill * 'Statistic Modifier' value) / 100



#91 (0x05B) Stat: Find Traps Modifier [91]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Skill = Skill + 'Statistic Modifier' value
1   Flat Value Modifier -> Skill = 'Statistic Modifier' value
2   Percentage Modifier -> Skill = (Skill * 'Statistic Modifier' value) / 100



#92 (0x05C) Stat: Pick Pockets Modifier [92]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Skill = Skill + 'Statistic Modifier' value
1   Flat Value Modifier -> Skill = 'Statistic Modifier' value
2   Percentage Modifier -> Skill = (Skill * 'Statistic Modifier' value) / 100



#93 (0x05D) Stat: Fatigue Modifier [93]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Skill = Skill + 'Statistic Modifier' value
1   Flat Value Modifier -> Skill = 'Statistic Modifier' value
2   Percentage Modifier -> Skill = (Skill * 'Statistic Modifier' value) / 100



#94 (0x05E) Stat: Drunkenness Modifier [94]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Skill = Skill + 'Statistic Modifier' value
1   Flat Value Modifier -> Skill = 'Statistic Modifier' value
2   Percentage Modifier -> Skill = (Skill * 'Statistic Modifier' value) / 100



#95 (0x05F) Stat: Tracking Skill Modifier [95]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Skill = Skill + 'Statistic Modifier' value
1   Flat Value Modifier -> Skill = 'Statistic Modifier' value
2   Percentage Modifier -> Skill = (Skill * 'Statistic Modifier' value) / 100



#96 (0x060) Stat: Level Change [96]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Level = Level + 'Statistic Modifier' value
1   Flat Value Modifier -> Level = 'Statistic Modifier' value
2   Percentage Modifier -> Level = (Level * 'Statistic Modifier' value) / 100



#97 (0x061) Stat: Strength-Bonus Modifier [97]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Bonus = Bonus + 'Statistic Modifier' value
1   Flat Value Modifier -> Bonus = 'Statistic Modifier' value
2   Percentage Modifier -> Bonus = (Bonus * 'Statistic Modifier' value) / 100



#98 (0x062) HP: Regeneration [98]
Parameter #1: Regeneration Amount
Parameter #2: Type
Description:
Restores HP to the value of 'Regeneration Amount' in the style specified by the 'Type' field, to the targeted creature(s).

Known values for 'Type' are:
1   Restore 'Regeneration Amount' as a percentage of total HP
2   Restore x HP every second
3   Restore 1HP every x seconds
4   Restore 'Regeneration Amount' per round

Permanent timing modes require a duration for this effect to work.



#99 (0x063) Spell Effect: Duration Modifier [99]
Parameter #1: Duration Modifier
Parameter #2: Type
Description:
Alters spell durations of the targeted creature(s), to the percentage specified by the 'Duration Modifier' field, affecting the spell type specified by the 'Type' field. Timing mode 0 is the only timing mode reliably affected.

eg.
'Duration Modifier' = 0   -> Spells have no duration
'Duration Modifier' = 100 -> Spells have normal duration
'Duration Modifier' = 200 -> Spells have double duration

Known values for 'Type' are:
0   Mage
1   Priest



#100 (0x064) Protection: from Creature Type [100]
Parameter #1: IDS Entry
Parameter #2: IDS File
Description:
Gives the targeted creature(s) protection from the creature type specified by the 'IDS File' and 'IDS Entry' fields.

Known values for 'IDS File' are:
2   EnemyAlly.ids
3   General.ids
4   Race.ids
5   Class.ids
6   Specific.ids
7   Gender.ids
8   Alignment.ids



#101 (0x065) Protection: from Opcode [101]
Parameter #1: Irrelevant
Parameter #2: opcode
Description:
Gives the targeted creature(s) protection from the opcode specified by the 'opcode' field.




#102 (0x066) Protection: from Spell Levels [102]
Parameter #1: Spell Power
Parameter #2: Irrelevant
Description:
Gives the targeted creature(s) protection from effects with a Power equal to that specified by the 'Spell Power' field.

Known values for 'Spell Power' are:
1
..
9



#103 (0x067) Text: Change Name [103]
Parameter #1: String Reference
Parameter #2: Irrelevant
Description:
Alters the name of the targeted creature(s) to the strref specified by the 'String Reference' field. When used with a duration timing, after the duration, the name will be set to a blank entry.



#104 (0x068) Stat: Experience Points [104]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> XP = XP + 'Statistic Modifier' value
1   Flat Value Modifier -> XP = 'Statistic Modifier' value
2   Percentage Modifier -> XP = (XP * 'Statistic Modifier' value) / 100



#105 (0x069) Stat: Gold [105]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Gold = Gold + 'Statistic Modifier' value
1   Flat Value Modifier -> Gold = 'Statistic Modifier' value
2   Percentage Modifier -> Gold = (Gold * 'Statistic Modifier' value) / 100

NB. This effect can only be used to lower the gold value.



#106 (0x06A) Stat: Morale Break Modifier [23]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Cumulative Modifier -> Morale Break = Morale Break + 'Statistic Modifier' value
1   Flat Value Modifier -> Morale Break = 'Statistic Modifier' value
2   Percentage Modifier -> Morale Break = (Morale * 'Statistic Modifier' value) / 100



#107 (0x06B) Portrait Change [107]
Parameter #1: Irrelevant
Parameter #2: Type
Description:
Sets the portrait of the targeted creature(s) to that specified in the resource key, based on the 'Type' value. This effect ignores durations attributed to it.

Known values for 'Type' are:
0   Small portrait
1   Large portrait



#108 (0x06C) Stat: Reputation [108]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Sets the individual reputation of the targeted creature(s) to the value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.
This does not affect the main reputation of the Party.

Known values for 'Type' are:
0   Cumulative Modifier -> Reputation = Reputation + 'Statistic Modifier' value
1   Flat Value Modifier -> Reputation = 'Statistic Modifier' value
2   Percentage Modifier -> Reputation = (Reputation * 'Statistic Modifier' value) / 100



#109 (0x06D) State: Hold [109]
Parameter #1: IDS Entry
Parameter #2: IDS File
Description:
Applies the hold effect to the targeted creature(s), if the targeted creature(s) match the value specified by the 'IDS Entry' field, in the specified 'IDS File'.

Known values for 'IDS File' are:
2   EA.ids
3   General.ids
4   Race.ids
5   Class.ids
6   Specific.ids
7   Gender.ids
8   Align.ids



#110 (0x06E) Empty: [110]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
This opcode has no effect.



#111 (0x06F) Item: Create Magical Weapon [111]
Parameter #1: Amount
Parameter #2: Irrelevant
Description:
Creates the item specified by the resource key. The number of items created is controlled by the 'Amount' field. The item is created in the Magical Weapon slot.



#112 (0x070) Item: Remove Item [112]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the item specified by the resource key from the targeted creature(s).



#113 (0x071) Empty: [113]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
This opcode has no effect.



#114 (0x072) Empty: [114]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
This opcode has no effect.



#115 (0x073) Detect: Alignment [115]
Parameter #1: Irrelevant
Parameter #2: Alignment Mask
Description:
Detects the alignment specified by the 'Alignment Mask' field.

Known values for 'Alignment Mask' are:
0   Evil (Glow red)
1   Neutral (Glow blue)
2   Good (Glow Green)



#116 (0x074) State: Cure Invisibility [116]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes invisibility from the targeted creature(s).



#117 (0x075) Spell Effect: Reveal Area [117]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Reveals the current area.

NB. This does not remove the fog of war.



#118 (0x076) Empty: [118]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
This opcode has no effect.



#119 (0x077) Spell Effect: Mirror Image [119]
Parameter #1: Irrelevant
Parameter #2: Type
Description:
Applies the mirror image effect to the targeted creature(s), creating mirror images in the style specified by the 'Type' field. The number of images is dicated by the level of the caster.

Know values for 'Type' are:
0  Normal
1  Reflected Image



#120 (0x078) Protection: from Melee Weapons [120]
Parameter #1: Enchantment
Parameter #2: Type
Description:
Gives the targeted creature(s) immunity to melee weapons as specified by the 'Type' field. The 'Enchantment' field is used if 'Type' is set to 0.

Known values for 'Type' are:
0  Enchantment
1  Magical
2  Non-Magical
3  Silver
4  Non-Silver
5  Silver / Non-Magical
6  Two-Handed
7  Non Two-Handed
8  Cursed
9  Non-Cursed
10 Cold-Iron
11 Non Cold-Iron



#121 (0x079) Empty: [121]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
This opcode has no effect.



#123 (0x07B) Item: Remove Inventory Item [123]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the item specified by the resource key from the targeted creature(s).



#124 (0x07C) Spell Effect: Teleport (Dimension Door) [124]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Teleports the targeted creature(s) in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Default
1   Source to Target
2   Return to Saved Location
3   Exchanged Source and Target



#125 (0x07D) Spell Effect: Unlock (Knock) [125]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the knock effect to the targeted creature(s).



#126 (0x07E) Stat: Movement Modifier [126]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

Values for 'Statistic Modifier' range from 0 (immobile) to 255 (instantaneous).

Known values for 'Type' are:
0   Cumulative Modifier -> Movement = Movement + 'Statistic Modifier' value
1   Flat Value Modifier -> Movement = 'Statistic Modifier' value
2   Percentage Modifier -> Movement = (Movement * 'Statistic Modifier' value) / 100



#127 (0x07F) Summon: Monster Summoning [127]
Parameter #1: Number
Parameter #2: Type
Description:
Summons a number of monsters.
Each creature files has a Creature Power Level number (at 0x18). The amount of monsters summoned by this effect is equal to the 'Number' field / Creature Power Level.
The 'Type' field set which 2da file to pick the creatures to summon from. The 2da files are monsumX and anisumX, where X = Type + 1. The specific 2da files used are:
0 MONSUM01 Monster Summon 1
1 MONSUM02 Monster Summon 2
2 MONSUM03 Monster Summon 3
3 ANISUM01 Animal Summon 1
4 ANISUM02 Animal Summon 2
5 MONSUM01 Monster Summon 1 Hostile
6 MONSUM02 Monster Summon 2 Hostile
7 MONSUM03 Monster Summon 3 Hostile
8 ANISUM01 Animal Summon 1 Hostile
9 ANISUM02 Animal Summon 2 Hostile

A custom .2da file can be entered in the resource field.

If used from an external effect (.eff), the vvc field controls the bam file played when summoning.



#128 (0x080) State: Confusion [128]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the confusion effect the targeted creature(s). The creature will run around uncontrollable, randomly attacking.



#129 (0x081) State: Aid [129]
Parameter #1: Statistic Modifier
Parameter #2: Irrelevant
Description:
Applies a bless effect, a bonus to HP and a bonus to saving throws to the targeted creature(s). The bonus is a number of 8-sided dice, with the number of dice controlled by the 'Statistic Modifier' value.



#130 (0x082) State: Bless [130]
Parameter #1: Modifier
Parameter #2: Irrelevant
Description:
Modifies the THAC0 and morale of the target creature(s) by the amount specified by the 'Modifier' parameter.



#131 (0x083) State: Positive Chant [131]
Parameter #1: Modifier
Parameter #2: Irrelevant
Description:
Applies the chant effect to the targeted creature(s). Chant affects the minimum damage caused by a weapon (up to the normal maximum damage of the weapon) and the attack roll modifier (up to a maximum of 20, excluding natural attack roll modifiers, e.g. high STR, invisibility etc) by 'Statistic Modifier' amount. The effect sets STATE_CHANT.

'Modifier' must be in the [-6,5] range.
Multiple chant effects are not cumulative.



#132 (0x084) State: Raise Strength, Constitution, & Dexterity Non-Cumulative [132]
Parameter #1: Statistic Modifier
Parameter #2: Irrelevant
Description:
Raises the strength, constitution and dexterity of the targeted creature(s) by the value specified by the 'Statistic Modifier' field. A negative value of 'Statistic Modifier' sets the strength, constitution and dexterity of the targeted creature(s) to 25.



#133 (0x085) Spell Effect: Luck Non-Cumulative [133]
Parameter #1: Statistic Modifier
Parameter #2: Irrelevant
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field to the targetted creatures luck. Luck affects the minimum damage caused by a weapon (up to the normal maximum damage of the weapon) and the attack roll modifier (up to a maximum of 20, excluding natural attack roll modifiers, e.g. high STR, invisibility etc) by 'Statistic Modifier' amount. The effect sets STATE_LUCK.



#134 (0x086) State: Petrification [134]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the petrification effect to the targeted creature(s). This effects kills & removes PC's from the party.



#135 (0x087) Graphics: Polymorph into Specific [135]
Parameter #1: Irrelevant
Parameter #2: Type
Description:
Polymorphs the targeted creature(s) into the creature specified by the resource key, in the style specified by the 'Type' field.

Known values for 'Type' are:
0   Resistances/statistics gained, spell-casting disabled, colouring
1   No resistances/statistics gained, spell-casting enabled, colouring
2   No resistances/statistics gained, spell-casting enabled, no colouring



#136 (0x088) State: Force Visible [136]
Parameter #1: Undefined
Parameter #2: Undefined
Description:
Renders the targeted creature(s) partially visible (does not remove the invisibility state, but the targeted is visible and attackable, but not targetable by spells).
The effect has no meaning on visible targets.
This effect has no duration.



#137 (0x089) State: Negative Chant [137]
Parameter #1: Modifier
Parameter #2: Irrelevant
Description:
Applies the chant effect to the targeted creature(s).
This effect works as the reverse of chant. The effect sets STATE_CHANTBAD.



#138 (0x08A) Graphics: Character Animation Change [138]
Parameter #1: Irrelevant
Parameter #2: Animation Sequence
Description:
The targeted creature(s) shows the animation sequence specified by the 'Animation Sequence' field.

Known values for 'Type' are:
1   Lay down (short)
2   Move hands (short)
3   Move hands (long)
4   Move shoulder (short)
5   Move shoulder (long)
6   Lay down (long)
7   Breath rapidly (short)
8   Breath rapidly (long)



#139 (0x08B) Text: Display String [139]
Parameter #1: String Reference
Parameter #2: Irrelevant
Description:
Displays the strref specified by the 'String Reference' value.



#140 (0x08C) Graphics: Casting Glow [140]
Parameter #1: Irrelevant
Parameter #2: Type
Description:
Creates a 2D animation for casting glow. These effects are usually used for casting glows based on the spell school.

Known values for 'Type' are:
0 .. 8 = Crash
9   Casting Glow Aqua (Necromancy)
10  Casting Glow Blue (Alteration)
11  Casting Glow Gold (Enchantment)
12  Casting Glow Green (Abjuration)
13  Casting Glow Magenta (Illusion)
14  Casting Glow Purple (Conjuration)
15  Casting Glow Red (Invocation)
16  Casting Glow White (Divination)
17+ Crashes



#141 (0x08D) Graphics: Lighting Effects [141]
Parameter #1: Irrelevant
Parameter #2: Type
Description:
Shows the lighting effect (a .bam file) specified by the 'Type' value. These effects are usually used for spell hits based on the spell school.

Known values for 'Type' are:
0   aqua SHAIR
1   aqua SHEARTH
2   aqua SHWATER
3   *crash*
4   blue SHAIR
5   blue SHEARTH
6   blue SHWATER
7   *crash*
8   gold SHAIR
9   gold SHEARTH
10  gold SHWATER
11  *crash*
12  green SHAIR
13  green SHEARTH
14  green SHWATER
15  *crash*
16  magenta SHAIR
17  magenta SHEARTH
18  magenta SHWATER
19  *crash*
20  purple SHAIR
21  purple SHEARTH
22  purple SHWATER
23  *crash*
24  red SHAIR
25  red SHEARTH
26  red SHWATER
27  *crash*
28  white SHAIR
29  white SHEARTH
30  white SHWATER
31  *crash*
32  red MUSHROOM
33  grey MUSHROOM
34  green MUSHROOM
35  red PILLAR
36  white PILLAR
37  white SWIRL



#142 (0x08E) Graphics: Display Special Effect Icon [142]
Parameter #1: Irrelevant
Parameter #2: Icon
Description:
Shows the icon specified by the 'Icon' field on the targeted creature(s) portrait.

Known values for 'Icon' are:
0   Charm
1   Dire Charm
2   Rigid Thinking
3   Confused
4   Beserk
5   Intoxicated
6   Poisoned
7   Diseased
8   Blind
9   Protection from Evil
10  Protection from Petrification
11  Protection from Normal Missiles
12  Armor
13  Held
14  Asleep
15  Shield
16  Protection from Fire
17  Bless
18  Chant
19  Free Action
20  Barkskin
21  Strength
22  Heroism
23  Spell Invulnerability
24  Protection from Acid
25  Protection from Cold
26  Resist Fire/Cold
27  Protection from Electricity
28  Protection from Magic
29  Protection from Undead
30  Protection from Poison
31  Non-detectable
32  Good luck
33  Bad luck
34  Silenced
35  Cursed
36  Panic
37  -
38  Level Up(?)
39  Hasted
40  Resist Fear
41  Slowed
42  Bard Song
43  Nauseous
44  Fatigued
45  Held
46  Spirit Armor
47  Hopelessness
48  Courage
49  Friends
50  Hope
51  Greater Malison
52  Spirit Armor
53  Dominated
54  Feebleminded
55  Tenser's Transformation
56  Mind Blank
57  Aid
58  Master Thievery
59  Draw Upon Holy Might
60  Miscast Magic
61  Strength of One
62  Prayer
63  Defensive Harmony
64  Recitation
65  Champion's Strength
66  Chaotic Commands
67  Righteous Wrath of the Faithful
68  Phased
69  Pain
70  Impervious Sanctity of Mind
71  Petrified
72  Iron Body
73  Animal Rage
74  Exaltation
75  Cat's Grace
76  Blood Rage
77  Ballad of Three Heroes
78  Tale of Curran Strongheart
79  Tymora's Melody
80  Song of Kaudies
81  Siren's Yearning
82  War Chant of Sith
83  Deaf
84  Armor of Faith



#143 (0x08F) Item: Create Item in Slot [143]
Parameter #1: Slot
Parameter #2: Irrelevant
Description:
Creates the item specified by the resource key in the slot specified by the 'Slot' field, on the targeted creature(s).

Known values for 'Slot' (from slots.ids) are:
0   AMULET
1   ARMOR
2   BELT
3   BOOTS
4   CLOAK
5   GAUNTLETS
6   HELMET
7   RING_LEFT
8   RING_RIGHT
9   SHIELD
10  FIST
11  AMMO
15  MISC
35  WEAPON
11  AMMO0
12  AMMO1
13  AMMO2
14  AMMO3
15  MISC0
16  MISC1
17  MISC2
18  MISC3
19  MISC4
20  MISC5
21  MISC6
22  MISC7
23  MISC8
24  MISC9
25  MISC10
26  MISC11
27  MISC12
28  MISC13
29  MISC14
30  MISC15
31  MISC16
32  MISC17
33  MISC18
34  MISC19
35  WEAPON0
36  WEAPON1
37  WEAPON2
38  WEAPON3



#144 (0x090) Button: Disable Button [144]
Parameter #1: Irrelevant
Parameter #2: Button
Description:
Disabled the button specified by the 'Button' field.

Known values for 'Button' are:
0   Stealth Button
1   Thieving Skill Button
2   Spell Select Button
3   First Quick Spell Button
4   Second Quick Spell Button
5   Third Quick Spell Button
6   N/A
7   Talk Button
8   Use Item Button
9   First Quick Item Button
11  Second Quick Item Button
12  Third Quick Item Button
13  Innate Ability Button

NB. This effect may be limited to values 0-7.



#145 (0x091) Spell: Disable Spell Casting Abilities [145]
Parameter #1: Irrelevant
Parameter #2: Spell Type
Description:
Disables spell casting abilities of the targeted creature(s), in the style specified by the 'Spell Type;' field.

Known values for 'Type' are:
0   Wizard
1   Priest
2   Innate



#146 (0x092) Spell: Cast Spell (at Creature) [146]
Parameter #1: Casting Level
Parameter #2: Type
Description:
Casts the spell specified by the resource key at the level specified by the 'Casting Level' field, in the style specified by the 'Type' field. A 'Casting Level' of 0 casts at the level of the casting creature.

Known values for 'Type' are:
0   Normal Casting
1   Cast Instantly



#147 (0x093) Spell: Learn Spell [147]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
The targeted creature(s) learn the spell specified by the resource key.



#148 (0x094) Spell: Cast Spell (at Point) [148]
Parameter #1: Casting Level
Parameter #2: Type
Description:
Casts the spell specified by the resource key, at the level specified by the 'Casting Level' field, in the style specified by the 'Type' field. A 'Casting Level' of 0 casts at the level of the casting creature.

Known values for 'Type' are:
0   Normal Casting
1   Cast Instantly



#149 (0x095) (Identify) [149]
Parameter #1: Undefined
Parameter #2: Undefined
Description:
The use of this effect is unknown, and effect of its parameters are undefined.



#150 (0x096) Spell Effect: Find Traps [150]
Parameter #1: Irrelev