[(BG2) bug] Spell schools for item abilities
Just like spells themselves, item abilities can have spell schools and secondary types. For the most part, these are taken from BG2's assignments and applied to BG items:
// match to underlying spell
COPY_EXISTING ~wand10.itm~ ~override~ // wand of monster summoning
READ_LONG 0x64 abil_off
READ_SHORT 0x68 abil_num
FOR (index = 0 ; index < abil_num ; ++index) BEGIN
WRITE_BYTE (abil_off + 0x17 + (index * 0x38)) 2 // school: conjuration
WRITE_BYTE (abil_off + 0x19 + (index * 0x38)) 6 // secondary: conjuration
END
BUT_ONLY
// match to underlying spell
COPY_EXISTING ~ring03.itm~ ~override~ // ring of animal friendship
~wand02.itm~ ~override~ // wand of fear
~wand04.itm~ ~override~ // wand of paralyzation
~wand08.itm~ ~override~ // wand of sleep
READ_LONG 0x64 abil_off
READ_SHORT 0x68 abil_num
FOR (index = 0 ; index < abil_num ; ++index) BEGIN
WRITE_BYTE (abil_off + 0x17 + (index * 0x38)) 4 // school: enchantment
WRITE_BYTE (abil_off + 0x19 + (index * 0x38)) 11 // secondary: disabling
END
BUT_ONLY
// match to underlying spell
COPY_EXISTING ~potn10.itm~ ~override~ // potion of invis
~ring05.itm~ ~override~ // invis ring
READ_LONG 0x64 abil_off
READ_SHORT 0x68 abil_num
FOR (index = 0 ; index < abil_num ; ++index) BEGIN
WRITE_BYTE (abil_off + 0x17 + (index * 0x38)) 5 // school: illusion
WRITE_BYTE (abil_off + 0x19 + (index * 0x38)) 3 // secondary: illusionary protections
END
BUT_ONLY
// match to underlying spell
COPY_EXISTING ~amul15.itm~ ~override~ // shield amulet
READ_LONG 0x64 abil_off
READ_SHORT 0x68 abil_num
FOR (index = 0 ; index < abil_num ; ++index) BEGIN
WRITE_BYTE (abil_off + 0x17 + (index * 0x38)) 6 // school: invocation
WRITE_BYTE (abil_off + 0x19 + (index * 0x38)) 7 // secondary: combat protections
END
BUT_ONLY
// match to underlying spell
COPY_EXISTING ~wand03.itm~ ~override~ // wand of magic missiles
~wand05.itm~ ~override~ // wand of fire
~wand06.itm~ ~override~ // wand of frost
~wand07.itm~ ~override~ // wand of lightning
~wand11.itm~ ~override~ // wand of the heavens
~wand12.itm~ ~override~ // wand of magic missiles
READ_LONG 0x64 abil_off
READ_SHORT 0x68 abil_num
FOR (index = 0 ; index < abil_num ; ++index) BEGIN
WRITE_BYTE (abil_off + 0x17 + (index * 0x38)) 6 // school: invocation
WRITE_BYTE (abil_off + 0x19 + (index * 0x38)) 10 // secondary: offensive damage
END
BUT_ONLY
// match to underlying spell
COPY_EXISTING ~chillt.itm~ ~override~ // chill touch
~ghoult.itm~ ~override~ // ghoul touch
READ_LONG 0x64 abil_off
READ_SHORT 0x68 abil_num
FOR (index = 0 ; index < abil_num ; ++index) BEGIN
WRITE_BYTE (abil_off + 0x17 + (index * 0x38)) 7 // school: necromancy
WRITE_BYTE (abil_off + 0x19 + (index * 0x38)) 7 // secondary: combination
END
BUT_ONLY
// match to underlying spell
COPY_EXISTING ~sgrasp.itm~ ~override~ // shocking grasp
READ_LONG 0x64 abil_off
READ_SHORT 0x68 abil_num
FOR (index = 0 ; index < abil_num ; ++index) BEGIN
WRITE_BYTE (abil_off + 0x17 + (index * 0x38)) 8 // school: transmutation
WRITE_BYTE (abil_off + 0x19 + (index * 0x38)) 10 // secondary: offensive damage
END
BUT_ONLY
Post edited by Tanthalas on
1
Comments
EDIT : Nevermind they're BG1 wands, not BG2. My bad I assumed stuff would be ported from BG2
Or the shield amulet will need another effect.
Probably time to change the shield amulet to resist the projectile?
@CamDawg Combination is 0xc (chillt.itm, ghoult.itm)
The other items are confirmed fixed.
Needs just that final fixed mentioned by @Avenger_teambg. (not sure what the chill and ghoul items are)
Editing WAND09, or is there some other thing wrong?
Matched to Conjurer(2)/ Conjuration(6)
WAND10
Matched to Enchanter(4)/ Disabling(11)
RING03
WAND02
WAND04
WAND08
Matched to Illusionist(5)/ Illusionary protections(3)
POTN10
RING05
Matched to Invoker(6)/ Combat protections(7)
AMUL15
Matched to Invoker(6)/ Offensive damage(10)
WAND03
WAND05
WAND06
WAND07
WAND11
WAND12
Matched to Necromancer(7)/ Combination(12)
CHILLT
GHOULT
Matched to Transmuter(8)/ Offensive damage(10)
SGRASP
Matched to Transmuter(8)/ Disabling(11)
WAND09 :-)
Not sure if they apply in-game effectively, but the ITMs were successfully assigned their proper primary and secondary school type.
@Humanoid_Taifun
hehe You managed to test the one wand that wasn't altered. ;-)
Then I don't understand this comment:
Ah, crumballs- sorry, you're right. I was just looking at the OP. I'll add that one from the later post...
also confirmed chill touch/ghoul touch changed to necromancy/combination (7-12)