Skip to content

[(BGEE, BG2) Bug] Miscast magic portrait icons

CamDawgCamDawg Member, Developer Posts: 3,438
edited August 2012 in Fixed
Currently, various spells will cause a chance for spells to fail but do not show a portrait icon to indicate this effect. This patch will add the miscast magic icon to these spells:
// miscast effects not accompanied by miscast icon
COPY_EXISTING ~spcl132.spl~ ~override~ // 25%, wrong icon (spell failure)
LAUNCH_PATCH_FUNCTION ~DELETE_SPELL_EFFECT~ INT_VAR
opcode_to_delete = "142" // delete existing portrait icons
END
LAUNCH_PATCH_FUNCTION ~ADD_SPELL_EFFECT~ INT_VAR
opcode = 142 // display portrait icon
target = 2 // preset target
resist_dispel = 2 // not dispel/bypass MR
duration = 90 // duration
parameter2 = 105 // icon: miscast magic
END
BUT_ONLY

// miscast effects not accompanied by miscast icon
COPY_EXISTING ~sppr310.spl~ ~override~ // 80%, no icon
LAUNCH_PATCH_FUNCTION ~ADD_SPELL_EFFECT~ INT_VAR
opcode = 142 // display portrait icon
target = 2 // preset target
resist_dispel = 1 // dispel/not bypass MR
duration = 60 // duration
power = 3 // power
parameter2 = 105 // icon: miscast magic
savingthrow = 1 // save vs spells
savebonus = 0xfffffffe // save at -2
END
BUT_ONLY

// miscast effects not accompanied by miscast icon
COPY_EXISTING ~sppr319.spl~ ~override~ // 80%, no icon
LAUNCH_PATCH_FUNCTION ~ADD_SPELL_EFFECT~ INT_VAR
opcode = 142 // display portrait icon
target = 2 // preset target
resist_dispel = 1 // dispel/not bypass MR
duration = 42 // duration
power = 3 // power
parameter2 = 105 // icon: miscast magic
savingthrow = 2 // save vs breath
savebonus = 0xfffffffc // save at -4
END
BUT_ONLY

// miscast effects not accompanied by miscast icon
COPY_EXISTING ~sppr986.spl~ ~override~ // 80%, no icon
READ_SHORT 0x68 "abil_num"
LAUNCH_PATCH_FUNCTION ~ADD_SPELL_EFFECT~ INT_VAR
opcode = 142 // display portrait icon
target = 2 // preset target
resist_dispel = 1 // dispel/not bypass MR
duration = 100 // duration
power = 3 // power
parameter2 = 105 // icon: miscast magic
savingthrow = 1 // save vs spells
savebonus = 0xfffffffe // save at -2
END
BUT_ONLY
Post edited by Bhryaen on

Comments

  • CorianderCoriander Member Posts: 1,667
    Let's do it!

    I mean I'll add this.
  • NathanNathan Member Posts: 1,007
    Verified, this has been implemented internally and should be present in the next build.
  • Avenger_teambgAvenger_teambg Member, Developer Posts: 5,862
    Confirmed fixed - checked that all magic resistance/saving throw fields in the portrait icon effect match the main effect.
  • BhryaenBhryaen Member Posts: 2,874
    Confirmed fixed:

    SPCL132- Icon changed from Spell failure (83) to Miscast magic (105).
    SPPR310- Display portrait icon (Miscast magic (105) added to effects.
    SPPR319- Display portrait icon (Miscast magic (105) added to effects.
    SPPR986- Display portrait icon (Miscast magic (105) added to effects.
Sign In or Register to comment.