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. If the targets AC is already 'AC Modifier' or below, this effect will do nothing).

AC is capped to the range [-20, 20]



#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
6        0.5
7        1.5
8        2.5
9        3.5
10      4.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
3   Cumulative Modifier -> Same as 0

NB. 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.

NB. Does not remove the state_helpless flag.



#3 (0x003) State: Berserking [3]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the berserk effect to the targeted creature(s). Target will uncontrollably attack enemies if any are in view, and will occasionally attack neutral creatures. The affected creature becomes berserk and its AI scripts stop running. Grants a +2 bonus to hit and damage with all weapons. It also sets the STATE_BERSERK flag. This opcode only affects party members.



#4 (0x004) Cure: Berserking [4]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the state_beserk flag from the targeted creature(s). This effect only affects Player Characters.
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
1000 Charmed (no text) (Target neutral after effect ends)
1001 Charmed (no text) (Target hostile after effect ends)
1002 Dire charmed (no text) (Target neutral after effect ends)
1003 Dire charmed (no text) (Target hostile after effect ends)
1004 Controlled by Cleric (no text)
1005 Target is hostile (no text)



#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

'Statistic Modifier' can be positive or negative.

With a Timing Modes of Permanent or Delayed, if 'Type' is 0 and 'Statistic Modifier' is positive, the statistic will alter and remain shown in white text, and a message 'Charisma raised permanently' will be shown.
With a Timing Modes of Permanent or Delayed, if 'Type' is 1 or 2, or 'Statistic Modifier' is negative, the statistic will alter and remain shown in white text, though no message is shown.
With all other Timing Modes, the statistic will alter and be shown in red text.



#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:
00   Belt Buckle (on armour) or amulets (on robes) - entire body for some animations
01   Minor colour
02   Major colour
03   Skin colour
04   Strap colour (on armour) or minor trimming (on robes - the centre strip down a robe and the hem on some robes)
05   Armor colour (and major trimming on robe - cross trim and cape trim on  robe of archmagi)
06   Hair colour
16   Quillons or Crossguard
20   Grip (usually not visible as it's in the characters hand)
21   Blade or major portion of weapon
32   Shield hub
33   Shield interior
34   Shield panelling
34   Helmet misc
37   Shield rim
48   Helm ornamentation - i.e. wings
49   Helm ornamentation - i.e. feathers/horsehair
50   Helm ornamentation - i.e. feathers/horsehair
52   Helm face
53   Helm - the main covering



#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:
00   Belt Buckle (on armour) or amulets (on robes) - entire body for some animations
01   Minor colour
02   Major colour
03   Skin colour
04   Strap colour (on armour) or minor trimming (on robes - the centre strip down a robe and the hem on some robes)
05   Armor colour (and major trimming on robe - cross trim and cape trim on  robe of archmagi)
06   Hair colour
16   Quillons or Crossguard
20   Grip (usually not visible as it's in the characters hand)
21   Blade or major portion of weapon
32   Shield hub
33   Shield interior
34   Shield panelling
34   Helmet misc
37   Shield rim
48   Helm ornamentation - i.e. wings
49   Helm ornamentation - i.e. feathers/horsehair
50   Helm ornamentation - i.e. feathers/horsehair
52   Helm face
53   Helm - the main covering



#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' field is handled as follows:
First byte = Location
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' are:
00   Belt Buckle (on armour) or amulets (on robes) - entire body for some animations
01   Minor colour
02   Major colour
03   Skin colour
04   Strap colour (on armour) or minor trimming (on robes - the centre strip down a robe and the hem on some robes)
05   Armor colour (and major trimming on robe - cross trim and cape trim on  robe of archmagi)
06   Hair colour
16   Quillons or Crossguard
20   Grip (usually not visible as it's in the characters hand)
21   Blade or major portion of weapon
32   Shield hub
33   Shield interior
34   Shield panelling
34   Helmet misc
37   Shield rim
48   Helm ornamentation - i.e. wings
49   Helm ornamentation - i.e. feathers/horsehair
50   Helm ornamentation - i.e. feathers/horsehair
52   Helm face
53   Helm - the main covering



#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 -> Constitution = Constitution + 'Statistic Modifier' value
1   Flat Value Modifier -> Constitution = 'Statistic Modifier' value
2   Percentage Modifier -> Constitution = (Constitution * 'Statistic Modifier' value) / 100

'Statistic Modifier' can be positive or negative.

With a Timing Modes of Permanent or Delayed, if 'Type' is 0 and 'Statistic Modifier' is positive, the statistic will alter and remain shown in white text, and a message 'Constitution raised permanently' will be shown.
With a Timing Modes of Permanent or Delayed, if 'Type' is 1 or 2, or 'Statistic Modifier' is negative, the statistic will alter and remain shown in white text, though no message is shown.
With all other Timing Modes, the statistic will alter and be shown in red text.



#11 (0x00B) Cure: Poison [11]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the poison effect from the targeted creature(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
3           Crushing Reduce by Percentage
65536       Acid
65537       Acid Set to Value
65538       Acid Set to Percentage
65539       Acid Reduce by Percentage
131072      Cold
131073      Cold Set to Value
131074      Cold Set to Percentage
131075      Cold Reduce by Percentage
262144      Electricity
262145      Electricity Set to Value
262146      Electricity Set to Percentage
262147      Electricity Reduce by Percentage
524288      Fire
524289      Fire Set to Value
524290      Fire Set to Percentage
524291      Fire Reduce by Percentage
1048576     Piercing
1048577     Piercing Set to Value
1048578     Piercing Set to Percentage
1048579     Piercing Reduce by Percentage
2097152     Poison
2097153     Poison Set to Value
2097154     Poison Set to Percentage
2097155     Poison Reduce by Percentage
4194304     Magic
4194305     Magic Set to Value
4194306     Magic Set to Percentage
4194307     Magic Reduce by Percentage
8388608     Missile
8388609     Missile Set to Value
8388610     Missile Set to Percentage
8388611     Missile Reduce by Percentage
16777216    Slashing
16777217    Slashing Set to Value
16777218    Slashing Set to Percentage
16777218    Slashing Reduce by Percentage
33554432    Magic Fire
33554433    Magic Fire Set to Value
33554434    Magic Fire Set to Percentage
33554435    Magic Fire Reduce by Percentage
67108864    Magic Cold
67108865    Magic Cold Set to Value
67108866    Magic Cold Set to Value
67108867    Magic Cold Reduce by Percentage
134217728   Stunning
134217729   Stunning Set to Value
134217730   Stunning Set to Percentage
134217731   Stunning Reduce by Percentage
268435456   Soul Eater
268435457   Soul Eater Set to Value
268435458   Soul Eater Set to Percentage
268435459   Soul Eater Reduce by Percentage
1073741824  Disease
1073741825  Disease Set to Value
1073741826  Disease Set to Percentage
1073741827  Disease Reduce by 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' or 'Magic Cold' 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   Chunked death
16  Stoned death
32  Freezing death
64  Exploding stoned death
128 Exploding freezing death
256 Electrified death
512 Disintegration 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

'Statistic Modifier' can be positive or negative.

With a Timing Modes of Permanent or Delayed, if 'Type' is 0 and 'Statistic Modifier' is positive, the statistic will alter and remain shown in white text, and a message 'Dexterity raised permanently' will be shown.
With a Timing Modes of Permanent or Delayed, if 'Type' is 1 or 2, or 'Statistic Modifier' is negative, the statistic will alter and remain shown in white text, though no message is shown.
With all other Timing Modes, the statistic will alter and be shown in red text.



#16 (0x010) State: Haste [16]
Parameter #1: Irrelevant
Parameter #2: Type
Description:
Applies the Haste effect, in the style specified by the 'Type' value.

Known values for 'Type' are:
0   Normal Haste
1   Improved Haste
2   Speed haste without attack bonuses

NB. 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.

NB. The upper word of the 'Type' field can further control the style.
Known values for the upper word of'Type' are:
1 Cure death
2 Removes all non timing-mode-9 effects
3 Cure death and remove non timing-mode-9 effects



#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 (affects current and max HP)
1   Flat Value Modifier -> HP = 'Statistic Modifier' value (affects current and max HP)
2   Percentage Modifier -> HP = (HP * 'Statistic Modifier' value) / 100 (affects current and max HP)

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. For non-permanent timing modes of 'Type' 2 or 5 use the base maximum HP value, and therefor override other 'Type' 2 or 5 modifiers.
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.

With a Timing Modes of Permanent or Delayed, if 'Type' is 0 and 'Statistic Modifier' is positive, the statistic will alter and remain shown in white text, and a message 'Intelligence raised permanently' will be shown.
With a Timing Modes of Permanent or Delayed, if 'Type' is 1 or 2, or 'Statistic Modifier' is negative, the statistic will alter and remain shown in white text, though no message is shown.
With all other Timing Modes, the statistic will alter and be shown in red text.



#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

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: Cumulative Luck Bonus [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. 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. 'Statistic Modifier' also affects the damge rolls of opponents (in feature blocks, not extension headers). The effect does not set STATE_LUCK.

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



#23 (0x017) Stat: Morale Modifier [23]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
Sets the Morale stat of the targetted creature(s) to 10.



#24 (0x018) State: Horror [24]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the horror effect to the targeted creature(s).



#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   Inflict 1HP per second (only if 'Damage Amount' is non-zero)
1   Inflict 1HP per second (only if 'Damage Amount' is greater than 1)
2   Inflict 'Damage Amount' per second
3   Inflict 1HP every 'Damage Amount' seconds
4   Inflict Param 3 Damage every Param 1 seconds
5+  Crash

NB. The 'Damage Amount' parameter should be set a positive value.



#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). A silenced creature cannot cast spells, use special abilities or initiate dialog. The engine is hard-coded to allow SPWI219 (Vocalize) and SPIN649 (Teleport to Pocket Plane) to be cast by a silenced creature.



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

NB. 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.

NB. 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. The colour field may be connected to sprkclr.2da.

Known values for 'Colour' are:
0   Crash
1   Black
2   Blue
3   Chromatic
4   Gold
5   Green
6   Purple
7   Red
8   White
9   Ice
10  Stone
11  Magenta
12  Orange
13  Crash+

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

Both of these params use only the lower 16 bits (upper bits might have other function).



#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
2   Level 2
4   Level 3
8   Level 4
16  Level 5
32  Level 6
64  Level 7
128 Level 8
256 Level 9

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. 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 = (Strength * 'Statistic Modifier' value) / 100

'Statistic Modifier' can be positive or negative.

With a Timing Modes of Permanent or Delayed, if 'Type' is 0 and 'Statistic Modifier' is positive, the statistic will alter and remain shown in white text, and a message 'Strength raised permanently' will be shown.
With a Timing Modes of Permanent or Delayed, if 'Type' is 1 or 2, or 'Statistic Modifier' is negative, the statistic will alter and remain shown in white text, though no message is shown.
With all other Timing Modes, the statistic will alter and be shown in red text.



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



#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: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the invisibility effect from the targeted creature(s).
This effect ignores durations attributed to it.



#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

'Statistic Modifier' can be positive or negative.

With a Timing Modes of Permanent or Delayed, if 'Type' is 0 and 'Statistic Modifier' is positive, the statistic will alter and remain shown in white text, and a message 'Wisdom raised permanently' will be shown.
With a Timing Modes of Permanent or Delayed, if 'Type' is 1 or 2, or 'Statistic Modifier' is negative, the statistic will alter and remain shown in white text, though no message is shown.
With all other Timing Modes, the statistic will alter and be shown in red text.



#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. The duration of the effect is controlled by the 'Speed' field.



#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:
00   Belt Buckle (on armour) or amulets (on robes) - entire body for some animations
01   Minor colour
02   Major colour
03   Skin colour
04   Strap colour (on armour) or minor trimming (on robes - the centre strip down a robe and the hem on some robes)
05   Armor colour (and major trimming on robe - cross trim and cape trim on  robe of archmagi)
06   Hair colour
16   Quillons or Crossguard
20   Grip (usually not visible as it's in the characters hand)
21   Blade or major portion of weapon
32   Shield hub
33   Shield interior
34   Shield panelling
34   Helmet misc
37   Shield rim
48   Helm ornamentation - i.e. wings
49   Helm ornamentation - i.e. feathers/horsehair
50   Helm ornamentation - i.e. feathers/horsehair
52   Helm face
53   Helm - the main covering



#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:
00   Belt Buckle (on armour) or amulets (on robes) - entire body for some animations
01   Minor colour
02   Major colour
03   Skin colour
04   Strap colour (on armour) or minor trimming (on robes - the centre strip down a robe and the hem on some robes)
05   Armor colour (and major trimming on robe - cross trim and cape trim on  robe of archmagi)
06   Hair colour
16   Quillons or Crossguard
20   Grip (usually not visible as it's in the characters hand)
21   Blade or major portion of weapon
32   Shield hub
33   Shield interior
34   Shield panelling
34   Helmet misc
37   Shield rim
48   Helm ornamentation - i.e. wings
49   Helm ornamentation - i.e. feathers/horsehair
50   Helm ornamentation - i.e. feathers/horsehair
52   Helm face
53   Helm - the main covering



#53 (0x035) Graphics: Animation Change [53]
Parameter #1: Animation ID
Parameter #2: Type
Description:
Alters the animation of the targeted creature(s) to the animation specified by the 'Animation ID' field, in the style specified by the 'Type' field.

Known values for Animation ID' are: (from animate.ids - in decimal)

Known values for 'Type' are:
0   Change animation - non-permanently
1   Remove any non-permanent animation change ('Animation ID' is unused)
2   Change animation - permanently



#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

NB. This effect adjusts the base stat, rather than modified THAC0.



#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, altering a the Move Silently skill.

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
3   Mage Spells
4   Cleric Spells
5   Innate

'Type' values of 0,1 or 2 display a message -'Spell Failed: casting failure'
'Type' values of 3,4 or 5 display a message -'Spell failed due to dead magic'



#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
2   Level 2
4   Level 3
8   Level 4
16  Level 5
32  Level 6
64  Level 7

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. 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).
This effect ignores durations attributed to it.

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: Irrelevant
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

This effect sets stat #60 (TRANSLUCENT) to param #1.



#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'. The Resource key should be set to the filename of the animation to play when unsummoning the creature, and defaults to SPGFLSH1 if left empty.

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), setting STATE_NONDETECTION while active. This effect is negated by effect #70 Cure: Non-Detection. While in the non-detection state, the creature is immune to effects #47: Cure Invisibility and #116: Remove invisibilty, though they are affected by effects that remove illusionary protections by school or secondary type.



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



#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)
The effect modifies stat 193.



#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   EA
1   Generic
2   Race
3   Class
4   Specific
5   Gender
6   Alignment



#73 (0x049) Stat: Extra Damage Modifier [73]
Parameter #1: Statistic Modifier
Parameter #2: Modifier Type
Description:
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field. The effect is an additive modifier, like adding +10 damage.

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



#74 (0x04A) State: Blindness [74]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the blindness effect to the targeted creature(s). This sets VISUALRANGE to 2, sets STATE_BLIND to true and incurs a cummulative 10 point base THAC0 penalty.



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



#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).
This effect ignores durations attributed to it.



#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:
0   1 HP per second
1   1 HP per second
2   'Damage' per Second
3   Cause 1HP every 'Damage' seconds
4   Strength Penalty
5   Dexterity Penalty
6   Constitution Penalty
7   Intelligence Penalty
8   Wisdom Penalty
9   Charisma Penalty
10  Slow Effect

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

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



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



#80 (0x050) State: Deafness [80]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the Deafness effect on the targeted creature(s) - creatures suffer a 50% 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).
This effect ignores durations attributed to it.



#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 [83]
Parameter #1: Irrelevant
Parameter #2: Type
Description:
Gives the targeted creature(s) immunity to the weapon type specified by the 'Type' value.

Values for 'Type' are taken from projectl.ids.



#84 (0x054) Stat: Magical Fire Resistance Modifier [84]
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



#85 (0x055) Stat: Magical Cold Resistance Modifier [85]
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



#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:
0   Restore 'Regeneration Amount' per second
1   Restore 'Regeneration Amount' as a percentage of total HP
2   Restore 'Regeneration Amount' HP every second
3   Restore 1HP every 'Regeneration Amount' seconds
4   Restore Param 3 HP every Param 1 seconds
5+  Crash

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. Timings handled through PRO files are ignored.

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   EA.ids
3   General.ids
4   Race.ids
5   Class.ids
6   Specific.ids
7   Gender.ids
8   Align.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 Level
Parameter #2: Irrelevant
Description:
Gives the targeted creature(s) protection from spells up to the level specified by the 'Spell Level' field. A spell is assigned to a spell level by the power level of the first effect greater than the 'Spell Level' parameter in the extended header that is being called.

Known values for 'Spell Level' 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. 'Type' 1 can only remove gold. Gold amount has a lower bound of 0.



#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. Though it can affect ranger/paladinhood of any target.

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

The affected creature becomes immobile and its AI scripts stop running.

This effect sets stat #58 (HELD) to 1. It also sets the STATE_HELPLESS flag.



#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 a single instance (or stack) of the item specified by the resource key from the targeted creature(s). Items in container items (e.g. Bags of Holding) will not be removed. If a creature has multiple instances of the item, the one in the lowest slot number (see slots.ids) is removed. EFF_M02 is hard-coded to play when an item is removed. This effect should be used to remove equipped items (use effect 123 for inventory items).



#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).
This effect ignores durations attributed to it.



#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: Irrelevant
Description:
Applies the mirror image effect to the targeted creature(s). The number of images is dicated by the level of the caster.



#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.



#122 (0x07A) Item: Create Inventory Item [122]
Parameter #1: Charges
Parameter #2: Irrelevant
Description:
Creates the item specified by the resource key. The number of items created is controlled by the 'Charges' field. The number of secondary charge is determined by P3. The number of tertiary charges is determined by P4 (external eff's). The item is created in the Inventory.



#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).  This effect should be used to remove inventory items (use effect 112 for equipped items).



#124 (0x07C) Spell Effect: Teleport (Dimension Door) [124]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Teleports the targeted creature(s).



#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.

The engine allows values for 'Statistic Modifier' from 0 (immobile) to 255 (instantaneous), though behaviour is only consistent in the range 0 - 30.

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. 0-4 are allied , 5-9 are hostile. 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, damage 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. 'Statistic Modifier' also affects the damge rolls of opponents (in feature blocks, not extension headers). 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, and ends the game if used on the Protagonist.



#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   Gain Resistances/statistics (spell-casting disabled)
1   Appearance only

This effect sets stat #59 (POLYMORPHED) to 1 but only if param #2 is 0.



#136 (0x088) State: Force Visible [136]
Parameter #1: Undefined
Parameter #2: Undefined
Description:
Renders the targeted creature(s) partially visible (does not remove improved invisibility, 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 (from SEQ.IDS):
0   Attack
1   Awake
2   Cast
3   Conjure
4   Damage
5   Die
6   Turn head
7   Ready
8   Shoot
9   Twitch
10  Walk
11  Attack (Slash)
12  Attack (Backslash)
13  Attack (Jab)
14  Emerge
15  Hide
16  Sleep



#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: Target
Parameter #2: Type
Description:
Shows the lighting effect (a .bam file) specified by the 'Type' value at the location specified by 'Target'. These effects are usually used for spell hits based on the spell school.

Known values for 'Target' are:
0      Current Location
Non-0  Target Location

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
38  Shadow Door (SPDIMDR)
39  Finger of Death (SPFDEATH)
40+ *crash*



#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.

All values are drawn directly from STATES.BAM in the GUIBam.bif starting at sequence 65.

Known values for 'Icon' are:
0   Charm
1   Dire Charm
2   Rigid Thinking
3   Confusion
4   Berserk
5   Intoxicated
6   Poisoned
7   Nauseated
8   Blind
9   Protection from Evil
10   Protection from Petrification
11   Protection from Missiles
12   Magic Armour
13   Held
14   Sleep
15   Shielded
16   Protection from Fire
17   Blessed
18   Chant
19   Free Action
20   Barkskin
21   Strength
22   Heroism
23   Invulnerable
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-detection
32   Good luck
33   Bad luck
34   Silenced
35   Cursed
36   Panic
37   Resist Fear
38   Haste
39   Fatigue
40   Bard Song
41   Slow
42   Regenerate
43   Domination
44   Hopelessness
45   Greater Malison
46   Spirit Armour
47   Chaos
48   Feebleminded
49   Defensive Harmony
50   Champion's Strength
51   Dying
52   Mind Shield
53   Level Drain
54   Polymorph Self
55   Stun
56   Regeneration
57   Perception
58   Master Thievery
59   Energy Drain (Psionic/Mindflayer)
60   Holy Power
61   Cloak of Fear
62   Iron Skins
63   Magic Resistance
64   Righteous Magic
65   Spell Turning
66   Repulsing Undead
67   Spell Deflection
68   Fire Shield Red
69   Fire Shield Blue
70   Protection from Normal Weapons
71   Protection from Magic Weapons
72   Tenser’s Transformation
73   Protection from Magical Energy
74   Mislead
75   Contingency Active
76   Protected from the Elements
77   Projected Image
78   Maze
79   Imprisonment
80   Stoneskin
81   KAI
82   Called Shot
83   Spell Failure
84   Offensive Stance
85   Defensive Stance
86   Intelligence Drained by Mind Flayer
87   Regenerating
88   Dialog Mode
89   At a Store
90   Negative Plane Protection
91   Ability Score Drained
92   Spell Sequencer Active
93   Protected from Energy
94   Magnetized
95   Able to Poison Weapons
96   Setting Trap
97   Glass Dust
98   Blade Barrier
99   Death Ward
100  Doom
101  Decaying
102  Acid
103  Vocalize
104  Mantle
105  Miscast Magic
106  Magic Resistance Lowered
107  Spell Immunity
108  True Seeing
109  Detecting Traps
110  Improved Haste
111  Spell Trigger
112  Deaf
113  Enfeebled
114  Infravision
115  Friends
116  Shield of the Archons
117  Spell Trap
118  Absolute Immunity
119  Improved Mantle
120  Farsight
121  Globe of Invulnerability
122  Minor Globe of Invulnerability
123  Spell Shield
124  Polymorphed
125  Otiluke’s Resilient Sphere
126  Nauseated
127  Ghost Armor
128  Glitterdust
129  Webbed
130  Unconscious
131  Mental Combat
132  Physical Mirror
133  Repulse Undead
134  Chaotic Commands
135  Draw Upon Holy Might
136  Strength of One
137  Bleeding
138  Barbarian Rage
139  Boon of Lathlander
140  Storm Shield
141  Enraged
142  Stunning Blow
143  Quivering Palm
144  Entangled
145  Grease
146  Smite
147  Hardiness
148  Power Attack
149  Whirlwind Attack
150  Greater Whirlwind
151  Magic Flue
152  Critical Strike
153  Greater Deathblow
154  Deathblow
155  Avoid Death
156  Assassination
157  Evasion
158  Greater Evasion
159  Improved Alacrity
160  Aura of Flaming Death
161  Globe of Blades
162  Improved Chaos Shield*
163  Chaos Shield*
164  Fire Elemental Transformation
165  Earth Elemental Transformation

Note: The engine refuses to show portrait 79 (Imprisonment).



#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. The resource field acts as a matching key to the resource field of the Enable Button, allowing separate enable/disable reasons.

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   Turn Undead Button
7   Talk Button
8   Use Item Button
9   First Quick Item Button
10  No effect
11  Second Quick Item Button
12  Third Quick Item Button
13  Innate Ability Button



#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) tries to learn the spell specified by the resource key.
Learning is successful when 1D100 <= the INT-dependent LEARN_SPELL value in INTBON.2DA.
The LEARN_SPELL value is modified for mage specialists, with +15 for same school spells, and -15 for non-same school spells.



#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) Empty: [149]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
This opcode has no effect.



#150 (0x096) Spell Effect: Find Traps [150]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the find traps effect to the targeted creature(s).



#151 (0x097) Summon: Replace Creature [151]
Parameter #1: Irrelevant
Parameter #2: Type
Description:
Replaces the targeted creature(s) with creature specified by the resource key, in the style specified by the 'Type' value.

Known values for 'Type' are:
0   Remove target silently
1   Remove target - kill with chunk death (giving experience)
2   Remove target - kill with normal death (giving experience)
3+  Don't remove the target



#152 (0x098) Spell Effect: Play Movie [152]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Plays the movie specified by the resource key.

Known movies are:
BG2-
 BISLOGO
 BWDRAGON
 DAYNITE
 DEATHAND
 END15FPS
 ENDCRDIT
 FLYTHR01
 FLYTHR02
 FLYTHR03
 FLYTHR04
 INTRO15F
 NITEDAY
 RESTCAMP
 RESTDUNG
 RESTINN
 WOTC

TOB-
 INTRO
 MANAFORG
 MELISSAN
 OUTRO
 SARADUSH
 POCKETZZ



#153 (0x099) Overlay: Sanctuary [153]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the sanctuary effect to the targeted creature(s).

This effect sets stat #63 (SANCTUARY) to 1.



#154 (0x09A) Overlay: Entangle [154]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the entangle visual effect to the targeted creature(s). Does not actually prevent the target from moving.

This effect sets stat #62 (ENTANGLE) to 1.



#155 (0x09B) Overlay: Minor Globe [155]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the minor globe visual effect to the targeted creature(s).

This effect sets stat #64 (MINORGLOBE) to 1.



#156 (0x09C) Overlay: Protection from Normal Missiles Cylinder [156]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the protection from normal missiles cylinder visual effect to the targeted creature(s).

This effect sets stat #65 (SHIELDGLOBE) to 1.



#157 (0x09D) State: Web Effect [157]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the web effect to the targeted creature(s). The affected creature becomes immobile and its AI scripts stop running.

This effect sets stats #58 (HELD) and #67 (WEB) to 1. It also sets the STATE_HELPLESS flag.



#158 (0x09E) Overlay: Grease [158]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the grease visual effect to the targeted creature(s). Does not actually affect the target's movement rate.

This effect sets stat #66 (GREASE) to 1.



#159 (0x09F) Spell Effect: Mirror Image (Exact Number) [159]
Parameter #1: Amount
Parameter #2: Irrelevant
Description:
Applies the mirror image effect to the targeted creature(s), creating a number of images equal to the 'Amount' value.



#160 (0x0A0) Remove Sanctuary [160]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the sanctuary effect from the targeted creature(s).



#161 (0x0A1) Cure: Horror [161]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the horror effect from the targeted creature(s).
This effect ignores durations attributed to it.



#162 (0x0A2) Cure: Hold [162]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the paralysis effect (opcodes 109 and 175) from the targeted creature(s).

This effect should be used with an instant timing mode.



#163 (0x0A3) Protection: Free Action [163]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the free action effect to the targeted creature(s), restoring the creatures movement rate to its default value if the current movement rate value is below the default for the animation type.



#164 (0x0A4) Cure: Drunkeness [164]
Parameter #1: Undefined
Parameter #2: Undefined
Description:
The use of this effect is unknown, and effect of its parameters are undefined.



#165 (0x0A5) Spell Effect: Pause Target [165]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the pause effect to the targeted creature(s). Characters are still selectable.

This effect sets stat #70 (CasterHold) to 1.



#166 (0x0A6) Stat: Magic Resistance Modifier [166]
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



#167 (0x0A7) Stat: THAC0 Modifier with Missile Weapons [167]
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



#168 (0x0A8) Summon: Remove Creature [168]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the creature specified by the resource key (giving no experience).



#169 (0x0A9) Graphics: Prevent Special Effect Icon [169]
Parameter #1: Irrelevant
Parameter #2: Icon
Description:
Prevents the icon specified by the 'Icon' field from being displayed.

All values are drawn directly from STATES.BAM in the GUIBam.bif starting at sequence 65.

Known values for 'Icon' are:
0   Charm
1   Dire Charm
2   Rigid Thinking
3   Confusion
4   Berserk
5   Intoxicated
6   Poisoned
7   Nauseated
8   Blind
9   Protection from Evil
10   Protection from Petrification
11   Protection from Missiles
12   Magic Armour
13   Held
14   Sleep
15   Shielded
16   Protection from Fire
17   Blessed
18   Chant
19   Free Action
20   Barkskin
21   Strength
22   Heroism
23   Invulnerable
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-detection
32   Good luck
33   Bad luck
34   Silenced
35   Cursed
36   Panic
37   Resist Fear
38   Haste
39   Fatigue
40   Bard Song
41   Slow
42   Regenerate
43   Domination
44   Hopelessness
45   Greater Malison
46   Spirit Armour
47   Chaos
48   Feebleminded
49   Defensive Harmony
50   Champion's Strength
51   Dying
52   Mind Shield
53   Level Drain
54   Polymorph Self
55   Stun
56   Regeneration
57   Perception
58   Master Thievery
59   Energy Drain (Psionic/Mindflayer)
60   Holy Power
61   Cloak of Fear
62   Iron Skins
63   Magic Resistance
64   Righteous Magic
65   Spell Turning
66   Repulsing Undead
67   Spell Deflection
68   Fire Shield Red
69   Fire Shield Blue
70   Protection from Normal Weapons
71   Protection from Magic Weapons
72   Tenser’s Transformation
73   Protection from Magical Energy
74   Mislead
75   Contingency Active
76   Protected from the Elements
77   Projected Image
78   Maze
79   Imprisonment
80   Stoneskin
81   KAI
82   Called Shot
83   Spell Failure
84   Offensive Stance
85   Defensive Stance
86   Intelligence Drained by Mind Flayer
87   Regenerating
88   Dialog Mode
89   At a Store
90   Negative Plane Protection
91   Ability Score Drained
92   Spell Sequencer Active
93   Protected from Energy
94   Magnetized
95   Able to Poison Weapons
96   Setting Trap
97   Glass Dust
98   Blade Barrier
99   Death Ward
100  Doom
101  Decaying
102  Acid
103  Vocalize
104  Mantle
105  Miscast Magic
106  Magic Resistance Lowered
107  Spell Immunity
108  True Seeing
109  Detecting Traps
110  Improved Haste
111  Spell Trigger
112  Deaf
113  Enfeebled
114  Infravision
115  Friends
116  Shield of the Archons
117  Spell Trap
118  Absolute Immunity
119  Improved Mantle
120  Farsight
121  Globe of Invulnerability
122  Minor Globe of Invulnerability
123  Spell Shield
124  Polymorphed
125  Otiluke’s Resilient Sphere
126  Nauseated
127  Ghost Armor
128  Glitterdust
129  Webbed
130  Unconscious
131  Mental Combat
132  Physical Mirror
133  Repulse Undead
134  Chaotic Commands
135  Draw Upon Holy Might
136  Strength of One
137  Bleeding
138  Barbarian Rage
139  Boon of Lathlander
140  Storm Shield
141  Enraged
142  Stunning Blow
143  Quivering Palm
144  Entangled
145  Grease
146  Smite
147  Hardiness
148  Power Attack
149  Whirlwind Attack
150  Greater Whirlwind
151  Magic Flue
152  Critical Strike
153  Greater Deathblow
154  Deathblow
155  Avoid Death
156  Assassination
157  Evasion
158  Greater Evasion
159  Improved Alacrity
160  Aura of Flaming Death
161  Globe of Blades
162  Improved Chaos Shield*
163  Chaos Shield*
164  Fire Elemental Transformation
165  Earth Elemental Transformation



#170 (0x0AA) Graphics: Play Damage Animation [170]
Parameter #1: Irrelevant
Parameter #2: Animation
Description:
Plays the damage animation specified by the 'Animation' field.

Known values for 'Type' are:
0   Blood (behind)
1   Blood (front)
2   Blood (left)
3   Blood (right)
4   Fire 1
5   Fire 2
6   Fire 3
7   Electricity 1
8   Electricity 2
9   Electricity 3



#171 (0x0AB) Spell: Give Ability [171]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Gives the spell specified by the resource key to the targeted creature(s).



#172 (0x0AC) Spell: Remove Spell [172]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the spell specified by the resource key from the targeted creature(s) spellbook (but does not affect spells already memorised).
Both parameters should be 0 (zero).



#173 (0x0AD) Stat: Set Poison Resistance [173]
Parameter #1: Statistic Modifier
Parameter #2: Irrelevant
Description:
Sets the Poison Resistance of the target creature(s) to the value specified by 'Statistic Modifier'.



#174 (0x0AE) Spell Effect: Play Sound Effect [174]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Plays the sound effect specified by the resource key.

Known Sound Effects are:
EFF_E01    Expire Illusionary Spell
EFF_E02    Expire Abjuration Spell
EFF_E03    Expire Conjuration Spell
EFF_E04    Expire Divination Spell
EFF_E05    Expire Enchantment Spell
EFF_E06    Expire Invocation Spell
EFF_E07    Expire Necromancy Spell
EFF_E08    Expire Alteration Spell

EFF_M02    Wizard Abjuration Spell Effect
EFF_M03    Wizard Conjuration Spell Effect
EFF_M04    Wizard Divination Spell Effect
EFF_M05    Wizard Enchantment Spell Effect
EFF_M07    Wizard Necromancy Spell Effect
EFF_M08    Wizard Alteration Spell Effect
EFF_M09    Dimension Door
EFF_M10    Dispel, Expire Illusionary Spell Effect
EFF_M11A   Expire Protection from Petrification
EFF_M11B   Expire Protection from Normal Missiles
EFF_M11C   Protection from Normal Missiles
EFF_M12A   Minor Globe Spell Effect
EFF_M12B   Expire Minor Globe Spell Effect
EFF_M13    Monster Summoning
EFF_M15    Wizard Hold Person/Undead/Monster
EFF_M16    Confusion Spell Effect
EFF_M18D   Melf's Acid Arrow
EFF_M20    Melf's Minute Meteors Impact
EFF_M20    Fireball Impact
EFF_M26    Animate Dead
EFF_M28    Haste
EFF_M29    Slow
EFF_M31A   Grease Area Effect Duration
EFF_M31B   Grease Start Area Effect
EFF_M31C   Grease Affect Creature
EFF_M32    Blur
EFF_M33    Wizard Illusionary Spell Effect
EFF_M34    Ice Storm
EFF_M35    Tree of Life Parasite Destruction
EFF_M36    Viekang Teleport
EFF_M36A   Skull Trap (untriggered)
EFF_M36B   Skull Trap shatter
EFF_M38    Teleport Without Error
EFF_M41    Disintegrate dust
EFF_M38    ic Armor
EFF_M52    Protection from Acid/Cold/Electricity/Fire
EFF_M53    Spell Protection Removal
EFF_M55    Weapon Protection Effect (e.g. Mantle, etc.)
EFF_M58    Melf's Minute Meteors creation
EFF_M59    Fire
EFF_M60    Stoneskin
EFF_M61    Polymorph/Shapeshift
EFF_M68    Melf's Acid Arrow Impact
EFF_M69    Improved Alacrity/Use Any Item
EFF_M70    Cacofiend, Gate, Summon Fiend
EFF_M71    Power Word: Blind, Kill, Silence, Sleep, Stun
EFF_M71B   Wizard Conjure Elemental Mental Combat
EFF_M71C   Wizard Conjure Elemental Mental Combat (Won)
EFF_M71D   Wizard Conjure Elemental Mental Combat (Lost)
EFF_M73    Summon Hakeashar, Nishruu
EFF_M74    Imprisonment, Maze 1
EFF_M74B   Imprisonment, Maze 2
EFF_M76    True Sight/Seeing
EFF_M77    Wizard Eye
EFF_M79    Spook
EFF_M80    Mislead, Project Image, Simulacrum
EFF_M82    Emotion, Greater Malison, Resist Magic
EFF_M86    Contingency & Sequencer -type spells
EFF_M87    Wizard Rapture of the Father
EFF_M89    Wail of the Banshee
EFF_M90    Timestop (Start)
EFF_M91    Timestop (Expire)
EFF_M92    Mirror Image/Priest Illusionary Spell Effect
EFF_M108   Dragon's Breath
EFF_M110   Bigby's Hand Spells

EFF_P01    Priest Abjuration Spell Effect
EFF_P02    Priest Conjuration Spell Effect
EFF_P03    Priest Divination Spell Effect
EFF_P04    Priest Enchantment Spell Effect
EFF_P05    Priest Invocation Spell Effect
EFF_P06    Priest Necromancy Spell Effect
EFF_P07    Priest Alteration Spell Effect
EFF_P08    Animal Summoning
EFF_P11    Hold Animal/Person (Priest)
EFF_P12    Protection from Evil/Magic Energy/The Elements/Energy
EFF_P13    Miscast Magic
EFF_P14    ic Vitriolic Sphere
EFF_P15    ic Recitation
EFF_P16    Flame Strike
EFF_P18    Raise Dead
EFF_P19    Call Lightning
EFF_P21A   Sanctuary Start
EFF_P21B   Sanctuary Duration
EFF_P21C   Sanctuary Expire
EFF_P22A   Glyph of Warding non-triggered
EFF_P22B   Glyph of Warding Shatter
EFF_P24    BG1 Armor/Shield
EFF_P25    Restoration (Lesser, Greater) casting completion
EFF_P40    Free Action
EFF_P43    Cloak of Fear start/Nature's Beauty
EFF_P51    Remove Fear
EFF_P54    Shillelagh, Spiritual Hammer
EFF_P55    Silence 15' radius
EFF_P56    Barkskin
EFF_P60    Aid
EFF_P61    Ironskins
EFF_P64A   Creature Summoning Flash
EFF_P65    Creature Summoning Circle
EFF_P66    Call Woodland Beings
EFF_P69    Unholy Word
EFF_P70    Holy Word
EFF_P72    Command Word
EFF_P73    Charm/Domination
EFF_P76    Flameblade
EFF_P77    Spiritual Hammer Hit
EFF_P80    Blade Barrier Creation
EFF_P83    Bolt of Glory
EFF_P89    Restoration (Greater, Lesser)
EFF_P90    Regeneration
EFF_P92    Earthquake
EFF_P93    Cause Wounds
EFF_P97    Armor of Faith wings
EFF_P115   Implosion
EFF_P116   Conjure Fallen Deva/Planetar
EFF_P117   Conjure Deva/Planetar



#175 (0x0AF) State: Hold [175]
Parameter #1: IDS Entry
Parameter #2: IDS File
Description:
Applies a yellow fade in graphic effect to the targeted creature(s), and shows the Hold icon, if the targeted creature(s) match the value specified by the 'IDS Entry' field, in the specified 'IDS File'. The affected creature becomes immobile and its AI scripts stop running.

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

This effect sets stat #58 (HELD) to 1. It also sets the STATE_HELPLESS flag.



#176 (0x0B0) Stat: Movement Modifier (II) [176]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
(As #126, but unaffected by Free Action).
Applies the modifier value specified by the 'Statistic Modifier' field in the style specified by the 'Type' field.

The engine allows values for 'Statistic Modifier' from 0 (immobile) to 255 (instantaneous), though behaviour is only consistent in the range 0 - 30.

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



#177 (0x0B1) Use EFF File [177]
Parameter #1: IDS Entry
Parameter #2: IDS File
Description:
Applies the eff file specified by the resource key to the targeted creature(s), if the targeted creature(s) match the value specified by the 'IDS Entry' field, in the specified 'IDS File'.
NB. When using an eff to alter thac0/dmg bonus, set param1 = 0, and param2 = 2.

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



#178 (0x0B2) Spell Effect: THAC0 vs. Creature Type Modifier [178]
Parameter #1: IDS Entry
Parameter #2: IDS File
Description:
Alters the targeted creature(s) THAC0 against the creature type specified by the 'IDS Entry' field in the specified 'IDS File'.
The actual modifier value is placed in the Parameter 3 field in an external effect.

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



#179 (0x0B3) Spell Effect: Damage vs. Creature Type Modifier [179]
Parameter #1: Reference Value
Parameter #2: Reference IDS
Description:
Alters the targeted creature(s) damage against the creature type specified by the 'IDS Entry' field in the specified 'IDS File'. The actual modifier value is placed in the Parameter 3 field in an external effect - dice values are ignored.

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



#180 (0x0B4) Item: Can't Use Item [180]
Parameter #1: String Reference
Parameter #2: Undefined
Description:
The targeted creatures(s) cannot use the item specified by the resource key. The strref specified by the 'String Reference' field is displayed when an attempt to use the item is made.



#181 (0x0B5) Item: Can't Use Itemtype [181]
Parameter #1: String Reference
Parameter #2: Type
Description:
The targeted creature(s) cannot use the item type specified by the 'Type' field. The strref specified by the 'String Reference' field is displayed when at attempt to use such an item is made.

This effect only works with 'Type' set to 0.



#182 (0x0B6) Item: Unknown [182]
Parameter #1: Unknown
Parameter #2: Unknown
Description:
The use of this effect is unknown, and effect of its parameters are undefined.



#183 (0x0B7) Item: Apply Effect Itemtype [183]
Parameter #1: Undetermined
Parameter #2: Type
Description:
Applies the effect specified by the resource key to the targeted creature(s) when an item of the item type specified by the 'Type' field is equipped.

***This effect has never been seen to work.***



#184 (0x0B8) Graphics: Passwall (Don't Jump) [184]
Parameter #1: Undefined
Parameter #2: Jump
Description:
Allows creatures to be placed in impassable areas, based on the value of the 'Jump' field.

Known values for 'Jump' are:
0   Do Jump from impassable areas
1+   Don't Jump from impassable areas



#185 (0x0B9) State: Hold [185]
Parameter #1: IDS Entry
Parameter #2: IDS File
Description:
Applies a yellow fade in graphic effect to the targeted creature(s), and shows the Hold icon, if the targeted creature(s) match the value specified by the 'IDS Entry' field, in the specified 'IDS File'. The affected creature becomes immobile and its AI scripts stop running.
This effect is not removed by effect 162.

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

This effect sets stat #58 (HELD) to 1. It also sets the STATE_HELPLESS flag.



#186 (0x0BA) Script: MoveToArea [186]
Parameter #1: Delay
Parameter #2: Orientation
Description:
Marks the targetted creature(s) as travelling to the area specified by the resource key. The creature appears in the specified area after a delay (specified by the 'Delay' field), with the orientation specified by the 'Orientation' field. The creature appears at the point specified by the Caster Point fields (external EFF files only).



#187 (0x0BB) Script: Store Local Variable [187]
Parameter #1: Value
Parameter #2: Irrelevant
Description:
This effect stores a various data types, usually a variable in the 'variable' field.

Resistance.param3: Point
Param4: Float
Param1: Int
Param2: Any
Resource1+2+3: String

This effect can only be used in an external effect (ie. an eff file).



#188 (0x0BC) Spell Effect: Aura Cleansing [188]
Parameter #1: Irrelevant
Parameter #2: Constant
Description:
Set the 'Constant' field to 1 if you want no time needed between spells.

This effect sets stat #76 (AURACLEANSING) to param #2.



#189 (0x0BD) Stat: Casting Time Modifier [189]
Parameter #1: Speed Modifier
Parameter #2: Irrelevant
Description:
Alters the casting time of spells by the value specified by the 'Speed Modifier' field. This effect is cummulative. Positive values decrease the casting time, negative values increase the casting time.

This effect sets stat #77 (MENTALSPEED) to param #1.



#190 (0x0BE) Stat: Attack Speed Factor [190]
Parameter #1: Speed Modifier
Parameter #2: Irrelevant
Description:
Alters the weapon's attack speed by the value specified by the 'Speed Modifier' field. This effect is not cumulative. Attack speed ranges from 0 (good) to 10 (bad). This effect acts as a bonus, so a high 'Speed Modifier' is good.

This effect sets stat #78 (PHYSICALSPEED) to param #1.



#191 (0x0BF) Spell: Casting Level Modifier [191]
Parameter #1: Modifier
Parameter #2: Type
Description:
Applies the value specified by the 'Modifier' field as a bonus to casting spell levels, of a type specified by the 'Type' field.

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

Note: This effect changes the casting level stat, but has no actual affect in-game.

This effect modifies stats #79 (CASTINGLEVELBONUSMAGE) or #80 (CASTINGLEVELBONUSCLERIC) depending on param #2.



#192 (0x0C0) Spell Effect: Find Familiar [192]
Parameter #1: Irrelevant
Parameter #2: Upgrade Marker
Description:
Summons a familiar for the Protagonist player. The familiar summoned is based on the alignment of the Protagonist, and values stored in the GAM file.

The 'Upgrade Marker' field is used internally to indicate the familiar has received the ToB upgrades.

Default creatures for familiars are:
Lawful Good     Pseudo Dragon (FAMPSD)
Lawful Neutral  Ferret (FAMFER)
Lawful Evil     Imp (FAMIMP)
Neutral Good    Pseudo Dragon (FAMPSD)
True Neutral    Rabbit (FAMRAB)
Neutral Evil    Dust Mephit (FAMDUST)
Chaotic Good    Fairy Dragon (FAMFAIR)
Chaotic Neutral Cat (FAMCAT)
Chaotic Evil    Quasit (FAMQUAS)



#193 (0x0C1) Spell Effect: Invisible Detection by Script [193]
Parameter #1: Irrelevant
Parameter #2: Constant Value
Description:
Allows invisible creatures to be attacked (via scripts) and makes it possible to target improved invisible creatures with spells. The Constant Value parameter should be set to 1 or 2.

This effect sets stat #81 (SEEINVISIBLE) to param #2.



#194 (0x0C2) Ignore Dialog Pause [194]
Parameter #1: Irrelevant
Parameter #2: Constant Value
Description:
Allows the targeted creature(s) to carry on their actions during dialogs which pause action.
The Constant Value parameter should be set to 1.



#195 (0x0C3) Spell Effect: Death Dependent Constitution Loss [195]
Parameter #1: HP Modifier
Parameter #2: Undefined
Description:
When a creature with this effect applied to it dies, the Protagonist enacts the damage animation, loses 1 Constitution point, and has their HP modified as dictated by the 'HP Modifier' field.
If 'HP Modifier' is positive, Maximum and Current HP are increased by 'HP Modifier' (though the message ' - was immune to my damage' is displayed).
If 'HP Modifier' is negative, Maximum HP is lowered by 'HP Modifier', and Current HP is lowered by twice 'HP Modifier'.



#196 (0x0C4) Spell Effect: Familiar Block [196]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
If this effect is found on any creature in the GAM file, the engine will block summoning of more familiars.

The effect should be set with a timing mode of 9.



#197 (0x0C5) Spell: Bounce Projectile [197]
Parameter #1: Irrelevant
Parameter #2: Reflected Projectile
Description:
The targeted creature(s) will reflect the projectile specified by the 'Reflected Projectile' field back to the attacker.

Values for 'Reflected Projectile' are taken from projectl.ids.



#198 (0x0C6) Spell: Bounce Opcode [198]
Parameter #1: Irrelevant
Parameter #2: Opcode
Description:
The targeted creature(s) will reflect attacks containing the opcode specified by the 'Opcode' field.

NB. This can cause a crash if two creatures end up reflecting to each other.



#199 (0x0C7) Spell: Bounce Spell Level [199]
Parameter #1: Reflected Level
Parameter #2: Irrelevant
Description:
The targeted creature(s) will reflect spells from the spell level specified in the 'Reflected Level' field.



#200 (0x0C8) Spell: Decrementing Bounce Spells [200]
Parameter #1: Amount
Parameter #2: Level
Description:
The targeted creature(s) will reflect a number of spells (specified by the 'Amount' field), from the spell level specified in the 'Level' field. A spell is assigned to a spell level by the power level of the first effect greater than the 'Level' parameter in the extended header that is being called.



#201 (0x0C9) Spell: Decrementing Spell Immunity [201]
Parameter #1: Amount
Parameter #2: Level
Description:
The targeted creature(s) will absorb a number of spells (specified by the 'Amount' field), from the spell level specified in the 'Level' field. A spell is assigned to a spell level by the power level of the first effect greater than the 'Level' parameter in the extended header that is being called.



#202 (0x0CA) Spell: Bounce Spell School [202]
Parameter #1: Irrelevant
Parameter #2: Spell School
Description:
The targeted creature(s) will turn spells from the school specified by the 'Spell School' field.

Known values for 'Spell School' are:
1   Abjuration
2   Conjuration
3   Divination
4   Enchantment
5   Illusion
6   Evocation
7   Necromancy
8   Alteration



#203 (0x0CB) Spell: Bounce Secondary Type [203]
Parameter #1: Irrelevant
Parameter #2: Secondary Type
Description:
The targeted creature(s) will turn spells with a secondary type matching that specified by the 'Secondary Type' field.

Known values for 'Secondary Type' are:
1   Spell Protections
2   Specific Protections
3   Illusionary Protections
4   Magic Attack
5   Divination Attack
6   Conjuration
7   Combat Protections
8   Contingency
9   Battleground
10  Offensive Damage
11  Disabling
12  Combination
13  Non-Combat



#204 (0x0CC) Spell: Protection from Spell (School) [204]
Parameter #1: Irrelevant
Parameter #2: Spell School
Description:
Gives the targeted creature(s) immunity to spells from the school specified by the 'Spell School' field.

Known values for 'Spell School' are:
1   Abjuration
2   Conjuration
3   Divination
4   Enchantment
5   Illusion
6   Evocation
7   Necromancy
8   Alteration



#205 (0x0CD) Spell: Protection from Spell (Secondary Type) [205]
Parameter #1: Irrelevant
Parameter #2: Type
Description:
Gives the targeted creature(s) immunity to the spell type specified by the 'Type' field.

Known values for 'Type' are:
1   Spell Protections
2   Specific Protections
3   Illusionary Protections
4   Magic Attack
5   Divination Attack
6   Conjuration
7   Combat Protections
8   Contingency
9   Battleground
10  Offensive Damage
11  Disabling
12  Combination
13  Non-Combat



#206 (0x0CE) Spell: Protection from Spell [206]
Parameter #1: String Reference
Parameter #2: Irrelevant
Description:
Gives the targeted creature(s) immunity from the spell specified in the resource key. The strref specified by the 'String Reference' field is displayed when the spell is absorbed.



#207 (0x0CF) Spell: Bounce Specified Spell [207]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
The targeted creature(s) will reflect the spell specified by the resource key.



#208 (0x0D0) HP: Minimum Limit [208]
Parameter #1: Minimum Value
Parameter #2: Irrelevant
Description:
The targeted creature(s) HP value will not drop below the value specified by the 'Minimum Value' field.

This effect sets stat #83 (MINHITPOINTS) to param #1.



#209 (0x0D1) Death: Kill 60HP [209]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Instantly kills the targeted creature(s), if the targeted creature(s) has less than 60 HP.



#210 (0x0D2) Spell Effect: Stun 90HP [210]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the stun effect to the targeted creature(s), if the targeted creature(s) has less than 90 HP.

The duration of the effect is:
1 to 29  HP -> stunned for 4d4 rounds
30 to 59 HP -> stunned for 2d4 rounds
60 to 89 HP -> stunned for 1d4 rounds



#211 (0x0D3) Spell Effect: Imprisonment [211]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the imprisonment effect to the targeted creature(s).

The field at 0xcc can be used to prevent death related effects (e.g. removal from party) running on the targetted creature(s).



#212 (0x0D4) Protection: Freedom [212]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the freedom effect to the targeted creature(s).
The freedom effect frees creatures trapped by the imprisonment effect.



#213 (0x0D5) Spell Effect: Maze [213]
Parameter #1: Type
Parameter #2: Irrelevant
Description:
Applies the maze effect to the targeted creature(s).

Known values for 'Type' are:
0   Use intelligence based duration (via intmod.2da)
1   Use duration field

The duration of the effect is set in intmod.2da, default values are:
0 to 2 int   -> 2d4 rounds
3 to 5 int   -> 1d4 rounds
6 to 8 int   -> 5d4 rounds
9 to 11 int  -> 4d4 rounds
12 to 14 int -> 3d4 rounds
15 to 17 int -> 2d4 rounds
18+ int      -> 1d4 rounds



#214 (0x0D6) Spell Effect: Select Spell [214]
Parameter #1: Irrelevant
Parameter #2: Type
Description:
Uses the 2da specified by the resource key to display multiple spell options, based on the 'Type' field.

Known values for 'Type' are:
1   Show only known spells

NB: To make your own 2DA file for, use the SPWI510.2DA as a base.



#215 (0x0D7) Graphics: Play 3D Effect [215]
Parameter #1: Undetermined
Parameter #2: Effect State
Description:
Plays the BAM/VVC specified by the resource key, in the style specified by the 'Effect State' value.

Known values for 'Effect State' are:
0   Play on target (not attached)
1   Play on target (attached)
2   Play on point

Known BAM files are:
acidblob   Ankheg Spit
aciddth    Acid Hit
bloodcr    Blood Splash
bloodl     Blood Splash (Large)
bloodm     Blood Splash (Medium)
bloods     Blood Splash (Small)
burnhand   Burning Hands
cgabjura   Casting Glow (Abjuration)
cgaltera   Casting Glow (Alteration)
cgconjur   Casting Glow (Conjuration)
cgdivina   Casting Glow (Divination)
cgenchan   Casting Glow (Enchantment)
cgillusi   Casting Glow (Illusion)
cginvoca   Casting Glow (Invocation)
cgnecrom   Casting Glow (Necromancy)
colrspry   Colour Spray
explode    Crash
fire       Crash
firebrn    Small Dot of Fire
flml       Bolt Of Flame (Large)
flmm       Small Bolt Of Flame (Medium)
flms       Tiny Bolt Of Flame (Small)
flmstrk    BG Flame Strike
glphwrdh   Glyph of Warding (Part)
glphwrdt   Glyph of Warding (Full)
greased    Blob Of Grease
greaseh    Blob Of Grease
grndglow   Grey round ground Explosion
hlymite    Call Upon Holy Might
magicstn   Magic Stone
minorglb   Minor Globe of Invulnerability
mmagich    Burst of Yellowish Magic (like Bolt Of Glory)
sanctry    Sanctuary
settrap    Spell Icon
shacid     Acid Damage
shair      Green mist rises from head to air above
sharea     Exploding Yellow Ring above head
shearth    Blue drops from chest drop on ground
shglyph    Rubbish
shskull    Rubbish
shwater    Potion of Healing
sklh is    Skull trap (moving)
sklt is    Skull Trap (stationary)
skybolt    Call Lightning
spabjura   Four cornered blue magic joins in middle
spagscho   Unexplainable
spaltera   Coloured magic rising from ground (Like Teleport Field)
spanisum   Opening Plant (find familiar)
sparmour2   Magic helm forms above target
sparmouri   golden armour joins together at chest of caster (armour)
sparmour   snowball like balls swirl around target
spattck1   Globe of magic (Like ruby ray of reversal)
spattck2   swirling small ball of magic (umber hulk confusion)
spbaserd   Golden Light with white rays of light coming from middle
spbasewt   Blue Light with white rays of light coming from middle
spbdbur    Lime green blob of magic
spbdburs   Direct Vertical Strike of greenish blue magic
spbdimsp   Greenish burst of magic upon target
spbehbla   Purplish magic swirling on target
spbehray   Fire like blob
spbhandi   Small ball of burning red fire
spblbbtm   Blade Barrier (bottom half)
spblbtop   Blade Barrier (Top Half)
spbleshi   3 Golden rays converging upon target
spblood    Chunk of flesh when body explodes due to too much damage
spboom     Mushroom like cloud of fire
spbrnhnd   Burning Hands
spburn     Tiny blob of fire
spburns1   Round fire
spcagemz   Maze (Only top 2 grates)
spcallli   Strike of Lightning (not lightning strike)
spccmdsi   Purplish red burst of magic
spccolde   Round of blue ice with a trail of smoke smashing on target
spccoldl   Travelling round blue ice with a trail of smoke
spccwoui   Burst of Bluish light bursting on target
spchlgt1   Chain Lightning
spchlgt2   Chain Lightning
spchlgt3   Chain Lightning
spchchromi Orb of Translucent bluish green magic
spchrorb   Chromatic Orb
spchunks   Ice Chunks (when target is frozen and smashed)
spclcomp   Blue cloud of mist
spclkfri   Blue Cloak forming on target (cloak of fear)
spcloud1   Blue Cloud of mist
spcloud2   A better Blue cloud of mist
spcloud3   Small cloud of blue mist
spcloudi   Burst of orangey red magic
spcmwoui   Blue magic on target increases then shrinks and disappears
spcomend   Tentacle Whip
spcomett   A Purple Comet
spcomstt   A whip
spconfus   Confusion a ring of intertwined birds
spcontin   A large white star forming a book which blasts white light
spcrtwpn   Yellow and white rays circle forming hammer and anvil
spcspra2   Coloured ball of magic
spcspra3   Larger more clearer ball of magic
spcsprai   Same as last one
spcswoui   Blast of greenish yellowey white magic
spdeath3   Rising spirit (Finger of Death)
spdimdr1   Bg open dimension door
spdimdr2   Bg opening dimension door
spdimndr   Bg2 dimension door
spdispma   Swirling balls of blue magic (dispel magic)
spdivina   Five balls of blue magic separating very small
spdusty2   Disintegration dust
spelltin   Rubbish green square
spentaai   Green vine from ground
spentaci   A swarm of green vines
spentaxi   A swarm of vines that disappear after intertwining
spfbsmal   White Ball of fire
spfdeath   Rising Spirit (Finger of Death)
spfdeth3   Rising Spirit (Finger Of Death)
spfearef   Face on ground (Horror)
spfinodi   A dieing Rose
spfire     Flame Damage
spfirebl   Fireball
spfirepl   Burst of fire in middle with a circle of white light leaving
spfiresb   Fire Shield Blue
spfiresr   Fire Shield Red
spfiret    Small Ball of Fire
spfiretr   Better Small Ball Of Fire
spfirimp   Fire Damage
spfirsdi   Burst of Flames
spfirsed   Fire Seed
spfladow   Flame Strike
spflames   Burst of Flames
spflast1   Burst Of Flames (Different)
spflast2   Flame Strike (different)
spfleshs   Swirling white rays (when Irenicus petrifies people)
spflmarr is Flame Arrow (more real)
spflmbld is Rising Sword
spflmsti is Bottom half Of Icewind Dale Style Flame Strike
spflsrin is Central flaming ball ejecting 2 rings of white light
spflstri is Flamestrike with burning bright yellow at bottom
spfracti is a chain breaking in half, spfstrmi is Small meteor swarm
spgenhla is Ray of bluish light with rays of yellow light (Holy Power)
spgenhlb is Ray Above but forming (the one above forms and finishes)
spgflsh1 is Burst of yellow red magic (when monsters unsummon)
spglyphi is Travelling Coloured glyph of warding
spglypti is Floating coloured glyph
spgreaai is Purple oval of magic
spgreaci is same oval of magic but still the one above forms and goes
spgreaxi is Blob of purple goo exploding on target
spgreorb is green Orb
sphandat is A electrical looking hand appearing
sphealin is Healing
sphleft is left Half of Icewind style Heal
sphlhi01 is left half of icewinds Heal
sphlhi02 is Right half of icewinds heal
sphlybls is Aid
sphlysm2 is Lighter Ray of Holy Smite
sphlysm3 is Darker ray of Holy Smite
sphlysmt is Yellow ray of light striking target
sphollyw is A swirl of blue magic forming then exploding into many doves
spholmig is Already formed circle of magic with white rays shining out
spholymt is Yellow ray with bluish mist on side vertically on target
spholywd is Light blue ray of vertical energy with whitish mist on side
sphorpuf is Yellowish puff of smoke
sphorwil is Abi Dalzims horrid wilting
sphright is Right hands side of Icewinds spell heal
spicestm is Ice storm
spillus is a ball of blue magic swirling
spilusio is a ball of blue magic swirling
spinsect is Black swarm of Insects
spiplaai is Brown swarm of insects
spiplari is Brown swarm of insects
spiplaui is Forming swarm of brown insects
splightb is Lightning Bolt
spmagglo is Minor Spell Deflection
spmagmis is Magic Missile
spmetswa is Flaming ball of fire
spmetswm is Meteor Swarm
spmetswn is More Balls of Meteor swarm
spmindat is The swirling ball above head when you are held
spmirroi is A shining blue mirror
spmonsum is Monster Summoning
spnecro1 is Ring of circling reddish purplish magic
spnpoisi is Icewinds style of cure disease
spnwchrm is Green orbs rising from ground to head (charm)
sppfirai is Produce Fire
sppfirri is smaller burst of fire
sppfirxi is larger burst of flame
spplanar is Large yellow orb forming then shattering
sppolymp is Polymorph
spportal is Round portal forming
sppowwrd is One of the red Power Word effects
spprayri is Icewind Dales style of prayer
spprism2 is swirling orb of colour
spprism3 is swirling ball of colour
spprismt is swirling ball of colour
spproimg is Crack in ground forming some round circle
spprotec is Protection from normal weapons
spraised is animate dead
spraisei is growing rose (raise dead)
sprdrabu is Vertical strike of red magic
sprdrae2 is burst of yellow fire like magic
sprdraex is burst of yellow fire like magic
sprdraim is puff of red smoke exploding on target in a ring
sprdrasi is puff of red smoke formed and it stays formed
spresuri is growing silver rose (resurrection)
spring is grey travelling ray
sprmpari is Icewind Style of remove paralysis
sprotect is Protection from evil
sprwra2i is A blue symbol on the ground with rays of blue rising from it
sprwrati is green ray forming and bursting down on target
spsarmour is Forming wings
spschgi is Purple energy with a black ring around it swirling
spscorch is Fire thing again (so many of these)
spscoric is same as above
spsdbur is A ray of misty grey magic vertically striking fast
spsdimpa is Great sparks of white bursting
spsdrbur is a ray of misty grey magic vertically striking
spshadow is Nothing
spshield is Prot normal missiles
spshkimp is Electrical damage effect
spskullt is red eyed skull with a trail of green smoke
spsmkjet is nothing
spsmold is nothing
spsmpuff is white round puff of smoke disappearing
spsnrayi is Sunray
spsohopi is Symbol forming and ejecting a ray of magic (symbol hopeless)
spspaini is Symbol of Pain
spsparks is sparks
spspeart is Bolt of Glory
spspmaze is 4 lines forming a sharp cage of spears
spstink is small puff of smoke rising from ground
spstones is stoneskin
spstrenh is Whiteray shooting down forming a puff of magic on target (lesser restoration)
spstreni is Strength of One
spsturni is Minor Spell Turning
spsumgte is gate (ring of bones)
spsummon is Call Woodland Beings
spsunray is Larger sunray
sptrapbb is Snare Trap
sptrusee is Opening Eye (clairvoyance)
spturni2 is Already formed spell turning
spunhbl2 is unholy smite
spunhbl3 is darker version of above
spunhblt is Red bolt shooting
spunholy is Am orange glow exploding into many doves
spwi124a is Spell Icon
spwi124b is Spell Icon
spwi124c is Spell Icon
spwirbla is Some ring forming a circle with other lines coming from it with blades arching up forming some cage
spwrdfld is Teleport Field
stnkcldd is Stinking Cloud
stnkcldt is Travelling Ball of Stinking Cloud
travel is An orb of swirling magic orb that shoots out to everyone
trbloba is green blob forming and splatting on target
trblobb is green blob forming and splatting on target
trdartst is Shooting knife looking things
trgooyaa is green blob forming and splatting on target
trgooybb is green blob forming and splatting on target
trspeart is Spear rising from ground striking target
trventaa is Bottom part of opening vent
trventbb is top part of opening vent which sprays out mist
webbomb is A burst of webs
webc is entangled in web
webentd  Other version of web
webenth  Entangling web
webentt  Travelling ball of shining web



#216 (0x0D8) Spell Effect: Level Drain [216]
Parameter #1: Amount
Parameter #2: Irrelevant
Description:
Drains levels from the targeted creature(s) as specified by the 'Amount' field. 'Amount' can be positive or negative, negative values will alter level and spellbook slots, but not experience.

Param3 is used internally to store recalculated max hp.
Param4 is used internally to store recalculated max xp.

This effect sets stat #200 (LEVELDRAIN) to param #1.



#217 (0x0D9) Spell Effect: Unconsciousness 20HP [217]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the unconsciousness effect to the targeted creature(s), if the targeted creature(s) has less than 20 HP. The effect always lasts 5 rounds, and ignores the duration field.



#218 (0x0DA) Protection: Stoneskin [218]
Parameter #1: Amount
Parameter #2: Irrelevant
Description:
Gives the targeted creature(s) a number of protections from physical attacks, as specified by the 'Amount' field.



#219 (0x0DB) Stat: AC vs. Creature Type Modifier [219]
Parameter #1: IDS Entry
Parameter #2: IDS File
Description:
Gives the targeted creature(s) a 2 point bonus AC against the creature type specified by the 'IDS Entry' in the IDS file specified by the 'IDS File' field.

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



#220 (0x0DC) Removal: Remove School [220]
Parameter #1: Maximum Level
Parameter #2: School Type
Description:
Removes spells from the school specified by the 'School Type' field from the targeted creature(s), up to the level specified by the 'Maximum level' field.

Known values for 'School Type' are:
1   Abjurer
2   Conjurer
3   Diviner
4   Enchanter
5   Illusionist
6   Invoker
7   Necromancer
8   Transmuter
9   Generalist



#221 (0x0DD) Removal: Remove Secondary Type [221]
Parameter #1: Maximum Level
Parameter #2: Secondary Type
Description:
Removes spells with a secondary type matching that specified by he 'Secondary Type' field from the targeted creature(s), up to the level specified by the 'Maximum level' field.

Known values for 'Secondary Type' are:
1   Spell Protections
2   Specific Protections
3   Illusionary Protections
4   Magic Attack
5   Divination Attack
6   Conjuration
7   Combat Protections
8   Contingency
9   Battleground
10  Offensive Damage
11  Disabling
12  Combination
13  Non-Combat



#222 (0x0DE) Spell Effect: Teleport Field [222]
Parameter #1: Max Range
Parameter #2: Irrelevant
Description:
Applies the teleport field to the targeted creature(s).
The 'Max Range' field sets the maximum range of the teleporting effect.



#223 (0x0DF) Spell Effect: Immunity School Decrement [223]
Parameter #1: Max Level
Parameter #2: School Type
Description:


Known values for 'School Type' are:
1   Abjurer
2   Conjurer
3   Diviner
4   Enchanter
5   Illusionist
6   Invoker
7   Necromancer
8   Transmuter
9   Generalist



#224 (0x0E0) Cure: Level Drain (Restoration) [224]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the restoration effect to the targeted creature(s), resetting the level of the target.



#225 (0x0E1) Spell: Reveal Magic [225]
Parameter #1: Undefined
Parameter #2: Undefined
Description:
Highlights the targeted creature(s) if they are affected by dispellable magic. The effect appears to be without duration.



#226 (0x0E2) Spell: Immunity Secondary Type Decrement [226]
Parameter #1: Max Level
Parameter #2: Secondary Type
Description:


Known values for 'Secondary Type' are:
1   Spell Protections
2   Specific Protections
3   Illusionary Protections
4   Magic Attack
5   Divination Attack
6   Conjuration
7   Combat Protections
8   Contingency
9   Battleground
10  Offensive Damage
11  Disabling
12  Combination
13  Non-Combat



#227 (0x0E3) Spell: Bounce School Decrement [227]
Parameter #1: Max Level
Parameter #2: School Type
Description:


Known values for 'School Type' are:
1   Abjurer
2   Conjurer
3   Diviner
4   Enchanter
5   Illusionist
6   Invoker
7   Necromancer
8   Transmuter
9   Generalist



#228 (0x0E4) Spell: Bounce Secondary Type Decrement [228]
Parameter #1: Max Level
Parameter #2: Secondary Type
Description:


Known values for 'Secondary Type' are:
1   Spell Protections
2   Specific Protections
3   Illusionary Protections
4   Magic Attack
5   Divination Attack
6   Conjuration
7   Combat Protections
8   Contingency
9   Battleground
10  Offensive Damage
11  Disabling
12  Combination
13  Non-Combat



#229 (0x0E5) Removal: Remove One School [229]
Parameter #1: Max Level
Parameter #2: School Type
Description:
Removes a single spell effect of the school specified by the 'School Type' field up to the 'Max Level' value, from the targeted creature(s).

Known values for 'School Type' are:
1   Abjurer
2   Conjurer
3   Diviner
4   Enchanter
5   Illusionist
6   Invoker
7   Necromancer
8   Transmuter
9   Generalist



#230 (0x0E6) Removal: Remove One Secondary Type [230]
Parameter #1: Max Level
Parameter #2: Secondary Type
Description:
Removes one spell effect of the school specified by the 'School Type' field up to the 'Max Level' value, from the targeted creature(s).

Known values for 'Secondary Type' are:
1   Spell Protections
2   Specific Protections
3   Illusionary Protections
4   Magic Attack
5   Divination Attack
6   Conjuration
7   Combat Protections
8   Contingency
9   Battleground
10  Offensive Damage
11  Disabling
12  Combination
13  Non-Combat



#231 (0x0E7) Spell Effect: Time Stop [231]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the time stop effect.
The timestop effect lasts half as long as the Duration specified for the effect.



#232 (0x0E8) Spell Effect: Cast Spell on Condition [232]
Parameter #1: Target
Parameter #2: Condition
Description:
Casts the spell specified by the resource field on the target specified by the 'Target' field, when the condition from the 'Condition' field is true. The conditions are akin to various triggers.

Known values for 'Target' are:
0   Effect Target
1   LastHitter
2   NearestEnemyOf
3   Nearest

Known values for 'Condition' are:
0   HitBy()
1   See(NearestEnemyOf())
2   HPPercentLT(Myself 50)
3   HPPercentLT(Myself 25)
4   HPPercentLT(Myself 10)
5   StateCheck(Myself,STATE_HELPLESS) i.e. unconscious
6   StateCheck(Myself,STATE_POISONED) i.e. poisoned
7   AttackedBy('Target')
8   PersonalSpaceDistance('Target',4)
9   PersonalSpaceDistance('Target',10)
10  Unknown - every round
11  TookDamage()

Parameter 3 (EFF) activates the portrait icon and immediately triggers the HitBy() trigger



#233 (0x0E9) Stat: Proficiency Modifier [233]
Parameter #1: Amount
Parameter #2: Type
Description:
Sets the weapon proficiency points for the weapon type specified in the 'Type' field, to the value specified by the 'Amount' field, for the targeted creature(s).

NB: The Proficiency Modifier effect cannot increment proficiency points, it can only SET them.
NB. The Proficiency Modifier cannot decrement the proficiency points.

Known values for 'Type' are:
Axe                          92
Bastard Sword                89
Blackjack                    108
Club                         115
Crossbow                     103
Dagger                       96
Darts                        106
Flail/Morningstar            100
Gun                          109
Halberd                      99
Katana                       94
Long Bow                     104
Long Sword                   90
Mace                         101
Martial Arts                 110
Quarter Staff                102
Scimitar/Wakizashi/Ninja-To  95
Short Bow                    105
Short Sword                  91
Single Weapon Skill          113
Sling                        107
Spear                        98
Sword and Shield Skill       112
Two-Handed Sword             93
Two-Handed Weapon Skill      111
Two Weapon Skill             114
War Hammer                   97
Extra Proficiency 2(Unused)  116
Extra Proficiency 3(Unused)  117
Extra Proficiency 4(Unused)  118
Extra Proficiency 5(Unused)  119
Extra Proficiency 6(Unused)  120
Extra Proficiency 7(Unused)  121
Extra Proficiency 8(Unused)  122
Extra Proficiency 9(Unused)  123
Extra Proficiency 10(Unused) 124
Extra Proficiency 11(Unused) 125
Extra Proficiency 12(Unused) 126
Extra Proficiency 13(Unused) 127
Extra Proficiency 14(Unused) 128
Extra Proficiency 15(Unused) 129
Extra Proficiency 16(Unused) 130
Extra Proficiency 17(Unused) 131
Extra Proficiency 18(Unused) 132
Extra Proficiency 19(Unused) 133
Extra Proficiency 20(Unused) 134



#234 (0x0EA) Spell Effect: Contingency Creation [234]
Parameter #1: Maximum Level Usable
Parameter #2: Amount/Type
Description:
Creates a contingency.
The 'Maximum Level' field indicates the maximum spell level that can be used in the contingency. The 'Amount/Type' field indicates the number of spells that can be used in the contingency, and the type of the contingency.

Known values for the 'Amount/Type' field are:
First word:
 0  Chain Contingeny
 1  Contingency
 2  Broken Sequencer
Second word: Amount



#235 (0x0EB) Spell Effect: Wing Buffet [235]
Parameter #1: Speed
Parameter #2: Direction
Description:
Applies the wing buffet effect centred on the casting creature(s), buffeting the targeted creature(s) at the speed specified by the 'Speed' field, in the direction specified by the 'Direction' field.

Known values for 'Direction' are:
0   As 1
1   Away from the destination point (specified in EFF file)
2   Away from the source
3   Towards the destination point (specified in EFF file)
4   Towards source

NB. If used on creatures with the passwall effect applied, creatures can cross points marked as light obstacles on the search map.
NB. Some animations are immune to this effect.



#236 (0x0EC) Spell Effect: Image Projection [236]
Parameter #1: Undetermined
Parameter #2: Type
Description:
Creates an image of the caster, in the style specified by the 'Type' field. The type can be accessed via CheckStat, stat ID: PUPPETTYPE.
NB. When creating an image for use as in Mislead, the image will have a script assigned, with scriptname of 'CASTERSCRIPTM' where CASTERERSCRIPT is the death variable of the casting creature.

Known values for 'Type' are:
0   Talkative, uncontrollable
1   Can not attack, can not cast spells (Mislead.spl is cast on the creature)
2   Can attack, can not cast spells (ProjImag.spl is cast on the creature)
3   Can attack, can cast spells (Simulacrs.pl is cast on the creature)
4+  As 0



#237 (0x0ED) Spell Effect: Puppet ID [237]
Parameter #1: Master ID
Parameter #2: ID Number
Description:
This effect stores information in a Projected Image/Simulacrum. The type can be accessed via CheckStat, stat PUPPETMASTERTYPE. Applying this effect to a non-image creature will set that creature to behave as an image (e.g. image casting, invisibility and talking behaviour).

Known values for 'ID Number' are:
1  Mislead
2  Project Image
3  Simulacrum

The 'Master ID' field stores a value (0-5) representing the owning party member.



#238 (0x0EE) Death: Disintegrate [238]
Parameter #1: IDS Entry
Parameter #2: IDS File
Description:
Disintegrates the targeted creature(s), if the targeted creature(s) match the 'IDS Entry' and in the specified 'IDS File', and if the targeted creature(s) hit-dice is less than those specified by the Dice Values.

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



#239 (0x0EF) Spell Effect: Farsight [239]
Parameter #1: Irrelevant
Parameter #2: Type
Description:
Allows viewing of the current area, based on the 'Type' field.

Known values for 'Type' are:
0   View explored sections only
1   View explored section and unexplored sections.



#240 (0x0F0) Graphics: Remove Special Effect Icon [240]
Parameter #1: Irrelevant
Parameter #2: Icon
Description:
Removes the icon specified by the 'Icon' field.

Known values for 'Icon' are:
0   Charm
1   Dire Charm
2   Rigid Thinking
3   Confusion
4   Berserk
5   Intoxicated
6   Poisoned
7   Nauseated
8   Blind
9   Protection from Evil
10   Protection from Petrification
11   Protection from Missiles
12   Magic Armour
13   Held
14   Sleep
15   Shielded
16   Protection from Fire
17   Blessed
18   Chant
19   Free Action
20   Barkskin
21   Strength
22   Heroism
23   Invulnerable
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-detection
32   Good luck
33   Bad luck
34   Silenced
35   Cursed
36   Panic
37   Resist Fear
38   Haste
39   Fatigue
40   Bard Song
41   Slow
42   Regenerate
43   Domination
44   Hopelessness
45   Greater Malison
46   Spirit Armour
47   Chaos
48   Feebleminded
49   Defensive Harmony
50   Champion's Strength
51   Dying
52   Mind Shield
53   Level Drain
54   Polymorph Self
55   Stun
56   Regeneration
57   Perception
58   Master Thievery
59   Energy Drain (Psionic/Mindflayer)
60   Holy Power
61   Cloak of Fear
62   Iron Skins
63   Magic Resistance
64   Righteous Magic
65   Spell Turning
66   Repulsing Undead
67   Spell Deflection
68   Fire Shield Red
69   Fire Shield Blue
70   Protection from Normal Weapons
71   Protection from Magic Weapons
72   Tenser’s Transformation
73   Protection from Magical Energy
74   Mislead
75   Contingency Active
76   Protected from the Elements
77   Projected Image
78   Maze
79   Imprisonment
80   Stoneskin
81   KAI
82   Called Shot
83   Spell Failure
84   Offensive Stance
85   Defensive Stance
86   Intelligence Drained by Mind Flayer
87   Regenerating
88   Dialog Mode
89   At a Store
90   Negative Plane Protection
91   Ability Score Drained
92   Spell Sequencer Active
93   Protected from Energy
94   Magnetized
95   Able to Poison Weapons
96   Setting Trap
97   Glass Dust
98   Blade Barrier
99   Death Ward
100  Doom
101  Decaying
102  Acid
103  Vocalize
104  Mantle
105  Miscast Magic
106  Magic Resistance Lowered
107  Spell Immunity
108  True Seeing
109  Detecting Traps
110  Improved Haste
111  Spell Trigger
112  Deaf
113  Enfeebled
114  Infravision
115  Friends
116  Shield of the Archons
117  Spell Trap
118  Absolute Immunity
119  Improved Mantle
120  Farsight
121  Globe of Invulnerability
122  Minor Globe of Invulnerability
123  Spell Shield
124  Polymorphed
125  Otiluke’s Resilient Sphere
126  Nauseated
127  Ghost Armor
128  Glitterdust
129  Webbed
130  Unconscious
131  Mental Combat
132  Physical Mirror
133  Repulse Undead
134  Chaotic Commands
135  Draw Upon Holy Might
136  Strength of One
137  Bleeding
138  Barbarian Rage
139  Boon of Lathlander
140  Storm Shield
141  Enraged
142  Stunning Blow
143  Quivering Palm
144  Entangled
145  Grease
146  Smite
147  Hardiness
148  Power Attack
149  Whirlwind Attack
150  Greater Whirlwind
151  Magic Flue
152  Critical Strike
153  Greater Deathblow
154  Deathblow
155  Avoid Death
156  Assassination
157  Evasion
158  Greater Evasion
159  Improved Alacrity
160  Aura of Flaming Death
161  Globe of Blades
162  Improved Chaos Shield*
163  Chaos Shield*
164  Fire Elemental Transformation
165  Earth Elemental Transformation



#241 (0x0F1) Charm: Control Creature [241]
Parameter #1: Creature ID
Parameter #2: Charm Type
Description:
As opcode #5



#242 (0x0F2) Cure: Confusion [242]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the confusion, rigid thinking and fear effect from the targeted creature(s).



#243 (0x0F3) Item: Drain Item Charges [243]
Parameter #1: Item Type
Parameter #2: Irrelevant
Description:
Items matching the 'Item Type' value on the targeted creature(s) will have their charges drained.

Known values for 'Item Type' are:
0   Magical items excluding weapons
1   Magical items including weapons

NB. This effect works in SoA but not ToB



#244 (0x0F4) Spell: Drain Wizard Spell [244]
Parameter #1: Number to Drain
Parameter #2: Irrelevant
Description:
Drains spells from a wizards memory. This effect always drains the highest level possible spell first and drains the number set by the Number to Drain parameter.



#245 (0x0F5) Check For Berserk [245]
Parameter #1: Undefined
Parameter #2: Undefined
Description:
This effect enables a 1% chance of the targetted creature(s) going berserk on each attack it makes. This affect sets the berserk stat changes and then attaches affect 246.



#246 (0x0F6) Spell Effect: Berserking [246]
Parameter #1: Undetermined
Parameter #2: Undetermined
Description:
This effect appears to be a combination of opcode #3 and the berserking portrait icon. This affect attaches affect 247.



#247 (0x0F7) Spell Effect: Attack Nearest Creature [247]
Parameter #1: Irrelevant
Parameter #2: Constant Value
Description:
Applies the attack nearest creature effect on the targeted creature(s).
This effect causes the targeted creature(s) to attack the nearest creature. The affected creature becomes berserk and its AI scripts stop running. Grants a +2 bonus to hit and damage with all weapons. Unlike opcode #3, this one can affect enemies as well.
The 'Constant Value' parameter should be non-zero.

This effect sets stat #144 (BERSERKSTAGE2) to param #2. It also sets the STATE_BERSERK flag.



#248 (0x0F8) Item: Set Melee Effect [248]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Sets the effect specified by the resource key as a melee effect.
The specified effect will be applied to the target of each successful melee attack.
The resource key references a .eff not a .spl.



#249 (0x0F9) Item: Set Ranged Effect [249]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Sets the effect specified by the resource key as a ranged effect.
The specified effect will be applied to the target of each successful ranged attack.
The resource key references a .eff not a .spl.



#250 (0x0FA) Spell Effect: Damage Modifier [250]
Parameter #1: Damage Modifier
Parameter #2: Irrelevant
Description:
Applies the 'Damage Modifier' value to the damage caused by the targetted creature(s). The effect works as a minimum damage value, i.e. at least 'Damage Modifier' damage will always be caused (on a successful hit).



#251 (0x0FB) Spell Effect: Change Bard Song Effect [251]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Sets the Bard Song of the targeted creature to the spell specified by the resource key.



#252 (0x0FC) Spell Effect: Set Trap [252]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Attempts to set the spell specified by the resource key as a trap.
This effect will fail if the targeted creature(s) does not have sufficient points in the 'Set Traps' skill.



#253 (0x0FD) Spell Effect: Add Map Marker [253]
Parameter #1: String Reference
Parameter #2: Irrelevant
Description:
Applies the set map marker effect.
The String Reference parameter is a string reference to the dialog.tlk file that sets what the marker says when the marker is read. The Target of this effect should be set to Self to function correctly.

NB. This effect works in SoA but not ToB



#254 (0x0FE) Spell Effect: Remove Map Marker [254]
Parameter #1: String Reference
Parameter #2: Irrelevant
Description:
Applies the remove map marker effect. This effect removes the map marker (if any) at the position the effect is cast. The Target of this effect should be set to Pre-Target to function correctly.

NB. This effect works in SoA but not ToB



#255 (0x0FF) Item: Create Inventory Item (days) [255]
Parameter #1: Charges
Parameter #2: Irrelevant
Description:
Creates the item specified by the resource key. The number of items created is controlled by the 'Charges' field. The number of secondary charge is determined by P3. The number of tertiary charges is determined by P4 (external eff's). The item is created in the Inventory, and has the 'can not steal' bit set.

NB. The difference from opcode #122 is that when used in an external .eff, the duration (from the calling file) is specified in days.



#256 (0x100) Spell: Spell Sequencer Active [256]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
This effect stores the spell resources for an active spell sequencer. The three spell resources are stored in the resource key, VVC field, and eff 3rd parameter.



#257 (0x101) Spell: Spell Sequencer Creation [257]
Parameter #1: Maximum Level Usable
Parameter #2: Amount
Description:
Creates a spell sequencer.
The 'Maximum Level' field indicates the maximum spell level that can be used in the sequencer. The 'Amount' field indicates the number of spells that can be used in the sequencer.
The filename of a spell containing this effect should be no more than 7 characters.



#258 (0x102) Spell: Spell Sequencer Activation [258]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Activates a spell sequencer.

The resource key must be set to the filename of the spell which contains the Spell Sequencer Creation effect, which must be an innate ability.
The spell which contains the Spell Sequencer Creation effect can have a maximum filename of 7 characters.
The spell which contains the Spell Sequencer Activation effect must have the same filename, suffixed with the D character.
eg:
 Spell Sequencer Creation filename = SPSS101
 Spell Sequencer Activation filename = SPSS101D



#259 (0x103) Protection: Spell Trap [259]
Parameter #1: Amount
Parameter #2: Level
Description:
Applies the spell-trap effect to the targeted creature(s), absorbing a number of spells as specified by the 'Amount' field, of the level specified by the 'Level' field, and recalling previously cast spells. A spell is assigned to a spell level by the power level of the first effect greater than the 'Level' parameter in the extended header that is being called.



#260 (0x104) Crash [260]
Parameter #1: Undefined
Parameter #2: Undefined
Description:
This effect crashes the game.



#261 (0x105) Spell: Restore Lost Spells [261]
Parameter #1: Spell Level
Parameter #2: Spell Type
Description:
Applies the restore lost spell effect to the targeted creature(s).
This effect will restore 1 spell to memory, at the level specified by the 'Spell Level' field, and of the type specified by the 'Spell Type' filed. If there is no free slot at the specified level, the effect restores a spell at the next lowest level possible.

Known values for 'Spell Type' are:
0   Wizard / Bard
1   Cleric / Druid



#262 (0x106) Stat: Visual Range [262]
Parameter #1: Visual Range
Parameter #2: Type
Description:
Applies the visual range effect to the targeted creature(s).
This effect modifies the visual range of the targeted creature(s).
The Visual Range parameter seems to be in the 0-15 interval.

Known values for 'Type' are:
0   Cumulative Modifier -> Visual Range = Visual Range + 'Visual Range' value
1   Flat Value Modifier -> Visual Range = 'Visual Range' value



#263 (0x107) Stat: Backstab [263]
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 -> Backstab = Backstab + 'Statistic Modifier' value
1   Flat Value Modifier -> Backstab = 'Statistic Modifier' value
2   Percentage Modifier -> Backstab = (Backstab * 'Statistic Modifier' value) / 100



#264 (0x108) Spell Effect: Drop Weapons in Panic [264]
Parameter #1: Irrelevant
Parameter #2: Type
Description:
Applies the drop weapons effect to the targeted creature(s), in the style specified by the 'Type' field.
This effect causes the targeted creature(s) to drop a piece of equipment.
It won't affect items marked as 'critical'

Known values for 'Type' are:
0   Drop random equipment
1   Drop a quickslot item (won't drop the left-hand weapon).



#265 (0x109) Script: Modify Global Variable [265]
Parameter #1: Value
Parameter #2: Type
Description:
Alters the global variable specified by the resource key, in the style specified by the 'Type' field, by the value specified by the 'Value' field.

Known values for 'Type' are:
0   Set Global (to 'Value')
1   Increment Global (by 'Value')

NB. Since the Resource Key can only be 8 characters long maximum, you can not set a Local Variable with this effect this has a name longer than this amount.
NB. You can use the VVC field of external EFF files for an additional 8 characters of variable name.
NB. You can use the 3rd resource field of EFF files for an additional 8 characters.

NB. All timing modes act as permanent for this effect.



#266 (0x10A) Spell: Remove Protection from Spell [266]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the protection from specific spell (as granted by #206) from the targeted creature(s) based on a matching resource key.



#267 (0x10B) Text: Protection from Display Specific String [267]
Parameter #1: String Reference
Parameter #2: Irrelevant
Description:
Prevents the strref specified by the 'String Reference' field being displayed by the targeted creature(s).



#268 (0x10C) Spell Effect: Clear Fog of War (Wizard Eye) [268]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Applies the clear fog of war effect on the targeted creature(s).
The targeted creature(s) will be able to explore like a PC does.

This effect sets stat #148 (EXPLORE) to 1.



#269 (0x10D) Spell Effect: Shake Window [269]
Parameter #1: Strength
Parameter #2: Undetermined
Description:
Applies the shake windows effect, with an intensity specified by the 'Strength' field



#270 (0x10E) Cure: Unpause Target [270]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the pause effect (#165) from the targeted creature(s).



#271 (0x10F) Graphics: Avatar Removal [271]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the animation of the targeted creature(s).



#272 (0x110) Spell: Apply Repeating EFF [272]
Parameter #1: Frequency
Parameter #2: Type
Description:
Applies the eff specified by the resource key to the targeted creature(s) as specified by the 'Type' field. 'Type' mode 4 makes use of Parameter 3, and so can only be used in external eff files.

Known values for 'Type' are:
0   Apply once per second
1   Crash
2   Apply 'Frequency' times per second
3   Apply once per 'Frequency' seconds
4   Apply Param 3 times per 'Frequency' rounds
5+  Crash

NB. The timings are relative to the movement rate of the affected creature(s). Effects 40 (Slow) and 78 (Disease) doubles the timing rate, effect 16 (Haste) halves the timing rate.
NB. If two or more effects of this type affect a creature, only the shortest duration effect will occur.



#273 (0x111) Remove: Specific Area Effect(Zone of Sweet Air) [273]
Parameter #1: Undetermined
Parameter #2: Undetermined
Description:
Removes projectiles listed in clearair.2da.



#274 (0x112) Spell Effect: Teleport to Target [274]
Parameter #1: Undetermined
Parameter #2: Undetermined
Description:
Teleports the affected creature(s) to a random enemy (i.e. party members would teleport to a red circled creature, red circled creatures teleport to the party). If there are no enemies within visual range, no effect will occur.



#275 (0x113) Stat: Hide in Shadows Modifier [275]
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



#276 (0x114) Stat: Detect Illusion Modifier [276]
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



#277 (0x115) Stat: Set Traps Modifier [277]
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



#278 (0x116) Stat: To Hit Modifier [278]
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 -> To-hit = To-hit + 'Statistic Modifier' value
1   Flat Value Modifier -> To-hit = 'Statistic Modifier' value
2   Percentage Modifier -> To-hit = (To-hit * 'Statistic Modifier' value) / 100

NB. This effect adjusts modified THAC0, rather than the base stat.



#279 (0x117) Button: Enable Button [279]
Parameter #1: Irrelevant
Parameter #2: Button
Description:
Enables the button specified by the 'Button Type' field. The resource field acts as a matching key to the resource field of the Enable Button, allowing separate enable/disable reasons.

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   Turn Undead Button
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



#280 (0x118) Spell Effect: Wild Magic [280]
Parameter #1: Irrelevant
Parameter #2: Type
Description:
Applies the wild magic effect to the targeted creature(s).
This effect causes other spells to be subject to wild magic throws.

Known values for 'Type' are:
1   Affect next spell cast
2   Affect all spells cast for effect duration



#281 (0x119) Stat: Wild Magic [281]
Parameter #1: Statistic Modifier
Parameter #2: Type
Description:
This effect will alter the wild-surge roll, making the resultant effect either more or less beneficial.
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 -> Chance = Chance + 'Statistic Modifier' value
1   Flat Value Modifier -> Chance = 'Statistic Modifier' value
2   Percentage Modifier -> Chance = (Chance * 'Statistic Modifier' value) / 100



#282 (0x11A) Script: Scripting State Modifier [282]
Parameter #1: Value
Parameter #2: Scripting State
Description:
Modifies Scripting state to the given value. Scripting State range from 0 to 35. The scripting state can be checked via scripts (see stats.ids), subtract 156 from the stat value to get the scripting state.

This effect does not have proper bounds checking, and can therefore be used in unintended ways. For example scripting state 13 equals with the NO_CIRCLE attribute (stat=169), and scripting state 1139 ties to PICKPOCKET (stat=29).



#283 (0x11B) Use EFF File (Cursed) [283]
Parameter #1: IDS Entry
Parameter #2: IDS File
Description:
Applies the eff file specified by the resource key to the targeted creature(s), if the targeted creature(s) match the 'IDS Entry' in the specified 'IDS File'. The eff can be removed via the Remove Curse opcode (in addition to other standard methods).

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



#284 (0x11C) Stat: Melee THAC0 Modifier [284]
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
The effect modifies stat 166.



#285 (0x11D) Stat: Melee Weapon Damage Modifier [285]
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
The effect modifies stat 167.



#286 (0x11E) Stat: Missile Weapon Damage Modifier [286]
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
The effect modifies stat 168.



#287 (0x11F) Graphics: Selection Circle Removal [287]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Removes the selection circle from the targeted creature(s).
The effect modifies stat 169.



#288 (0x120) Stat: Fist THAC0 Modifier [288]
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
The effect modifies stat 170.



#289 (0x121) Stat: Fist Damage Modifier [289]
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
The effect modifies stat 171.



#290 (0x122) Text: Change Title [290]
Parameter #1: String Reference
Parameter #2: Position
Description:
Changes the title of the targeted creature(s), to the strref specified by the 'String Reference' field, at the location specified by the 'Position' field.

Known values for 'Position' are:
0   Records Screen information section
1   Various character screens (eg. Inventory and Records Screen)
The effect modifies stats 172 and 173.



#291 (0x123) Graphics: Disable Visual Effect [291]
Parameter #1: Irrelevant
Parameter #2: Constant Value
Description:
Disables the glowing disk from some effect on the targeted creature(s). Does not affect those visual effects which use BAM files - eg. Fire Shield (red).
The Constant Value parameter should be set to 1.
The effect modifies stat 174 to param2.



#292 (0x124) Protection: Backstab [292]
Parameter #1: Irrelevant
Parameter #2: Constant Value
Description:
Makes the targeted creature(s) immune to backstabbing.
The Constant Value parameter should be set to 1.
The effect modifies stat 175 to param2.



#293 (0x125) Script: Enable Offscreen AI [293]
Parameter #1: Irrelevant
Parameter #2: Constant Value
Description:
The targeted creature(s) will still run scripts when off-screen and out of combat.
The Constant Value parameter should be set to 1.
The effect modifies stat 183 to param2.



#294 (0x126) Spell Effect: Existance Delay Override [294]
Parameter #1: Undefined
Parameter #2: Constant Value
Description:
Existance is the verbal constant group from 69 to 74 (or 70-74). These sounds are randomly played (for non global, alive characters, when not in cutscene or dialog). This stat tunes the frequency of these random strings.

Known values for 'Constant Value' are:
-1 - no existance sounds
0  - standard existance sound frequency
Other values - random existance sound frequency (the higher the rarer)
The effect modifies stat 184, unless param2 is set to 1.



#295 (0x127) Graphics: Disable Permanent Death [295]
Parameter #1: Undefined
Parameter #2: Constant Value
Description:
This targeted creature(s) will never suffer a permanent death (and will therefore always remain resurrectable) - exceptions include petrification and freeze-death.
The Constant Value parameter should be set to 1, and timing mode should be 9 (Permanent after Death).
The effect modifies stat 186.



#296 (0x128) Graphics: Protection from Specific Animation [296]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
Provides the targeted creature(s) with immunity to the animation specified by the resource key



#297 (0x129) Spell Effect: Immunity to Turn Undead [297]
Parameter #1: Undefined
Parameter #2: Constant Value
Description:
Makes the targeted creature(s) immune to the Turn Undead effect.
Constant Value should be non-zero.
The effect modifies stat 187.



#298 (0x12A) Spell Effect: Execute Script cut250a [298]
Parameter #1: Irrelevant
Parameter #2: Constant Value
Description:
Executes script cut250a.bcs. By default this script teleports the party to the Pocket Plane area (AR4500).
The Constant Value parameter should be set to 1.



#299 (0x12B) Spell Effect: Chaos Shield [299]
Parameter #1: Shield Amount
Parameter #2: Icon
Description:
This effect defends against wild surges and displays an associated icon as specified by the 'Icon' parameter.

Known values for 'Icon' are:
0  Normal Chaos Shield
1  Improved Chaos Shield

The effect modifies stat 189.



#300 (0x12C) Spell Effect: NPCBump [300]
Parameter #1: Unknown
Parameter #2: Constant Value
Description:
This effect allows the targetted creature(s) to push other creatures out of the way while moving.
Constant Value should be set to 1.
The effect modifies stat 190 to param 2.



#301 (0x12D) Stat: Critical Hit Modifier [301]
Parameter #1: Statistic Modifier
Parameter #2: Irrelevant
Description:
This effect improves the Critical Hit chances.
Critical hits will occur on a roll (on a 1d20) greater or equal to:
20 - 'Statistic Modifier'



#302 (0x12E) Item: Can Use Any Item [302]
Parameter #1: Irrelevant
Parameter #2: Constant Value
Description:
The targeted creature(s) can use any item.
The Constant Value parameter should be set to 1.
The effect modifies stat 191.



#303 (0x12F) Spell Effect: Backstab Every Hit [303]
Parameter #1: Irrelevant
Parameter #2: Constant Value
Description:
The targeted creature(s) will backstab with every hit.
The Constant Value parameter should be set to 1.
The effect modifies stat 192.



#304 (0x130) Mass Raise Dead [304]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
This effect will raise multiple dead PCs and NPCs.



#305 (0x131) Stat: THAC0 Modifier (Off-Hand) [305]
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



#306 (0x132) Stat: THAC0 Modifier (On-Hand) [306]
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



#307 (0x133) Ranger Tracking Ability [307]
Parameter #1: Range
Parameter #2: Irrelevant
Description:
Activates the Tracking Ability. A string from tracking.2da is shown, and arrows appear along the screen edge pointing to any creatures within range. The units of the range parameter are unknown.
The arrow effect may be hardcoded to spell SPCL922.

NB: The file 'tracking.2da' lists the string reference that shows what information is learned from using this effect for each area.



#308 (0x134) Protection: From Tracking [308]
Parameter #1: Irrelevant
Parameter #2: Constant value
Description:
Protects the targetted creature(s) from the Tracking arrows effect (has no affect on the area string displayed).
The effect modifies stat 195 to the value of param type.



#309 (0x135) Script: Modify Local Variable [309]
Parameter #1: Value
Parameter #2: Type
Description:
Set both the local variable specified by the resource key to the value specified by the 'Value' field.

Known values for 'Type' are:
0   Set Local (to 'Value')
1   Increment Local (by 'Value')

NB: Since the Resource Key can only be 8 characters long maximum, you can not set a variable with this Effect this has a name longer than this amount.
You can use the VVC field of external EFF files for an additional 8 characters of variable name.
You can use the 3rd resource field of EFF files for an additional 8 characters.



#310 (0x136) Protection: from Timestop [310]
Parameter #1: Irrelevant
Parameter #2: Constant Value
Description:
The targeted creature(s) becomes immune to time-stop.
The Constant Value parameter should be set to 1.
The effect modifies stat 197.



#311 (0x137) Spell: Random Wish Spell [311]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
This effect casts a wish spell (SPWISH01 - SPWISH25), selected based on the casting creatures Wisdom attribute, as outlined below.

SPWISHxx    MinWis    MaxWis
01          10        25
02          10        25
03          10        25
04          10        25
05          0         25
06          10        25
07          0         25
08          15        25
09          0         25
10          0         25
11          0         25
12          0         25
13          0         25
14          0         25
15          15        25
16          0         25
17          0         25
18          0         17
19          0         9
20          0         17
21          0         17
22          0         9
23          0         9
24          0         9
25          0         25



#312 (0x138) Crash [312]
Parameter #1: Undefined
Parameter #2: Undefined
Description:
This effect crashes the game.
This opcode is also known as ImmunityToSequester.



#313 (0x139) High-Level Ability Denotation [313]
Parameter #1: Undetermined
Parameter #2: Undetermined
Description:
This effect denotes that the high level ability specified by the resource key has been gained. Used for pre-requisites/count limits.



#314 (0x13A) Spell: Golem Stoneskin [314]
Parameter #1: Amount
Parameter #2: Irrelevant
Description:
Gives the targeted creature(s) a number of protections from physical attacks, as specified by the 'Amount' field.

NB: Do not use this effect in conjunction with the Juggernaut Golem Manual as it will corrupt the use of that item.



#315 (0x13B) Graphics: Animation Removal [315]
Parameter #1: Irrelevant
Parameter #2: Constant Value
Description:
This effect will remove the animation of the targeted creature(s).
The Constant Value parameter should be set to a non-zero value.
The effect modifies stat 201.



#316 (0x13C) Spell: Magical Rest [316]
Parameter #1: Irrelevant
Parameter #2: Irrelevant
Description:
This effect will refresh spells and remove any fatigue.



#317 (0x13D) State: Haste 2 [317]
Parameter #1: Irrelevant
Parameter #2: Type
Description:
Applies the Haste effect, in the style specified by the 'Type' value.

Known values for 'Type' are:
0   Normal Haste
1   Improved Haste
2   Speed haste without attack bonuses

The effect modifies stat 155.
NB. This effect will cancel out the slow opcode.