[(BGEE, BG2) Bug] Flame blade fixes
Flame blade is currently doing 1d2+4 slashing and 1d4 fire damage and includes a +4 to hit bonus. Per its descript, it should be hitting for 1d4 slashing and 1d2+4 fire damage and conferring no thac0 bonus. Flame blade also lacks a name at present:
// per descript flame blade does 1d4 slashing damage plus 1d2 + 4 fire damage
// actual item does 1d2 + 4 slashing damage plus 1d4 fire, and has a spurious thac0 bonus
COPY_EXISTING ~fblade.itm~ ~override~
SAY NAME1 #10951 // flame blade
SAY NAME1 #10951 // flame blade
READ_LONG 0x64 "abil_off"
READ_SHORT 0x68 "abil_num"
READ_LONG 0x6a "fx_off"
READ_SHORT 0x70 "fx_num"
FOR (index = 0 ; index < abil_num ; index = index + 1) BEGIN // looks for melee ability header
READ_BYTE ("%abil_off%" + ("%index%" * 0x38)) "type"
PATCH_IF ("%type%" = 1) BEGIN // melee ability check
WRITE_SHORT ("%abil_off%" + 0x14 + ("%index%" * 0x38)) 0 // thac0 bonus
WRITE_SHORT ("%abil_off%" + 0x16 + ("%index%" * 0x38)) 4 // dice size, melee damage
WRITE_SHORT ("%abil_off%" + 0x1a + ("%index%" * 0x38)) 0 // fixed melee damage
READ_SHORT ("%abil_off%" + 0x1e + ("%index%" * 0x38)) "abil_fx_num"
READ_SHORT ("%abil_off%" + 0x20 + ("%index%" * 0x38)) "abil_fx_idx"
FOR (index2 = 0 ; index2 < abil_fx_num ; index2 = index2 + 1) BEGIN // searches through fx for fire damage
READ_SHORT ("%fx_off%" + (("%abil_fx_idx%" + "%index2%") * 0x30)) "opcode"
READ_SHORT ("%fx_off%" + 0x0a + (("%abil_fx_idx%" + "%index2%") * 0x30)) "damage_type"
PATCH_IF (("%opcode%" = 12) AND ("%damage_type%" = 8)) BEGIN // fire damage
WRITE_LONG ("%fx_off%" + 0x04 + (("%abil_fx_idx%" + "%index2%") * 0x30)) 4 // fixed fire damage
WRITE_LONG ("%fx_off%" + 0x20 + (("%abil_fx_idx%" + "%index2%") * 0x30)) 2 // dice size, fire damage
END
END
END
END
BUT_ONLY_IF_IT_CHANGES
Post edited by Bhryaen on
3
Comments
-Galactygon
"With this spell, the caster causes a blazing ray of red-hot fire to spring forth from his hand. This blade-like ray is wielded as if it were a sword that the caster already knows how to use, hence there are no bonuses or penalties."
-Galactygon
Suggested behaviour:
Either place additional flags "double damages at critical hits" and "increase damage at backstabs" at 0x26 of the extended header,
or allow additional conditions of opcodes 248 and 249 (set melee/ranged effect) to allow certain effects to be fired in a critical hit.
-Galactygon
slashing 1d4 (works with critical and backstab)
fire dmg 1d2+4
no thac0 bonus
Tooltip/Name set.
Item Ability effect:
Damage type: FIRE - 8
Fixed Damage: 4
Dice size/ Min level: 2
# dice / Max level: 1
(Looks like 1-2 + 4 Fire Dam to me...)
Item Ability:
Damage type: Slashing (3)
To hit: 0
# dice: 1
Dicesize: 4
Damagebonus: 0
(Looks like 1d4 slashing with no dam or THAC0 bonus to me...)
Confirmed Fixed