Jump to content

SpPr711; SpWi307; SpWi511


Recommended Posts

In my copy of ToB:

 

Regeneration uses a different animation at level 15 than every other level (MagRes instead of SpWratI).

 

Protection from Normal Weapons displays some funk ass string for the level 1 protection from SpWi611.

 

Invisibility 10' foot looks to use a projectile that targets everybody. I vote for InAreaPa. Yes, those play sounds really are target: self (look at Protection from Normal Missiles for more).

 

Dispel Magic uses a dispel/resist setting of 1 for the VVC, which will cause a "Magic Resistance" message to pop up for chars with high MR. This, of course, afflicts every single spell and item they copied the effects to (probably 20 or so). Fun!

Link to comment
Regeneration uses a different animation at level 15 than every other level (MagRes instead of SpWratI).

 

// wrong vvc for regen at lvl 15
COPY_EXISTING ~sppr711.spl~ ~override~
 READ_LONG  0x64 "abil_off"
 READ_SHORT 0x68 "abil_num"
 READ_LONG  0x6a "fx_off"
 FOR (index = 0 ; index < abil_num ; index = index + 1 ) BEGIN // cycle thru abilities
   READ_SHORT  ("%abil_off%" + 0x1e + (0x28 * "%index%")) "abil_fx_num"
   READ_SHORT  ("%abil_off%" + 0x20 + (0x28 * "%index%")) "abil_fx_idx"
   FOR (index2 = 0 ; index2 < abil_fx_num ; index2 = index2 + 1) BEGIN
     READ_SHORT ("%fx_off%" +        (0x30 * ("%index2%" + "%abil_fx_idx%"))) "opcode"
     READ_ASCII ("%fx_off%" + 0x14 + (0x30 * ("%index2%" + "%abil_fx_idx%"))) "resref"
     PATCH_IF (("%opcode%" = 215) AND ("%resref%" STRING_COMPARE_CASE "magres" = 0)) BEGIN
       WRITE_ASCII ("%fx_off%" + 0x14 + (0x30 * ("%index2%" + "%abil_fx_idx%"))) "icwrati" #8
     END
   END
 END
 BUT_ONLY_IF_IT_CHANGES

 

Protection from Normal Weapons displays some funk ass string for the level 1 protection from SpWi611.

 

// wrong string for pfnw's protection from pfmw spell
COPY_EXISTING ~spwi511.spl~ ~override~
 READ_LONG  0x64 "abil_off"
 READ_SHORT 0x68 "abil_num"
 READ_LONG  0x6a "fx_off"
 FOR (index = 0 ; index < abil_num ; index = index + 1 ) BEGIN // cycle thru abilities
   READ_SHORT  ("%abil_off%" + 0x1e + (0x28 * "%index%")) "abil_fx_num"
   READ_SHORT  ("%abil_off%" + 0x20 + (0x28 * "%index%")) "abil_fx_idx"
   FOR (index2 = 0 ; index2 < abil_fx_num ; index2 = index2 + 1) BEGIN
     READ_SHORT ("%fx_off%" +        (0x30 * ("%index2%" + "%abil_fx_idx%"))) "opcode"
     READ_ASCII ("%fx_off%" + 0x14 + (0x30 * ("%index2%" + "%abil_fx_idx%"))) "resref"
     PATCH_IF (("%opcode%" = 206) AND ("%resref%" STRING_COMPARE_CASE "spwi611" = 0)) BEGIN // replace s&s descript
       WRITE_LONG ("%fx_off%" + 0x04 + (0x30 * ("%index2%" + "%abil_fx_idx%"))) 36743
     END
   END
 END
 BUT_ONLY_IF_IT_CHANGES

 

Invisibility 10' foot looks to use a projectile that targets everybody. I vote for InAreaPa. Yes, those play sounds really are target: self (look at Protection from Normal Missiles for more).

 

I'm not too chuffed about the projectile--the description does say it'll affect all creatures in the radius. Added to the existing duration patch:

 

// incorrect duration, targeting for invis 10'
COPY_EXISTING ~spwi307.spl~ ~override~
 READ_LONG  0x64 "abil_off"
 READ_SHORT 0x68 "abil_num"
 READ_LONG  0x6a "fx_off"
 FOR (index = 0 ; index < abil_num ; index = index + 1 ) BEGIN // cycle thru abilities
   READ_SHORT  ("%abil_off%" + 0x1e + (0x28 * "%index%")) "abil_fx_num"
   READ_SHORT  ("%abil_off%" + 0x20 + (0x28 * "%index%")) "abil_fx_idx"
   FOR (index2 = 0 ; index2 < abil_fx_num ; index2 = index2 + 1) BEGIN
     READ_SHORT ("%fx_off%" +        (0x30 * ("%index2%" + "%abil_fx_idx%"))) "opcode"
     READ_LONG  ("%fx_off%" + 0x0e + (0x30 * ("%index2%" + "%abil_fx_idx%"))) "duration"
     PATCH_IF ("%duration%" = 300) BEGIN
       WRITE_LONG ("%fx_off%" + 0x0e + (0x30 * ("%index2%" + "%abil_fx_idx%"))) 7200
     END
     PATCH_IF ("%opcode%" = 174) BEGIN
       WRITE_BYTE ("%fx_off%" + 0x02 + (0x30 * ("%index2%" + "%abil_fx_idx%"))) 2 // target: preset target
     END
   END
 END
 BUT_ONLY_IF_IT_CHANGES

// bad targets for pfnm sound effect targeting
COPY_EXISTING ~spra303.spl~ ~override~ // avenger
             ~spwi311.spl~ ~override~ // generic arcane
 READ_LONG  0x64 "abil_off"
 READ_SHORT 0x68 "abil_num"
 READ_LONG  0x6a "fx_off"
 FOR (index = 0 ; index < abil_num ; index = index + 1 ) BEGIN // cycle thru abilities
   READ_SHORT  ("%abil_off%" + 0x1e + (0x28 * "%index%")) "abil_fx_num"
   READ_SHORT  ("%abil_off%" + 0x20 + (0x28 * "%index%")) "abil_fx_idx"
   FOR (index2 = 0 ; index2 < abil_fx_num ; index2 = index2 + 1) BEGIN
     READ_SHORT ("%fx_off%" +        (0x30 * ("%index2%" + "%abil_fx_idx%"))) "opcode"
     PATCH_IF ("%opcode%" = 174) BEGIN
       WRITE_BYTE ("%fx_off%" + 0x02 + (0x30 * ("%index2%" + "%abil_fx_idx%"))) 2 // target: preset target
     END
   END
 END
 BUT_ONLY_IF_IT_CHANGES

 

Dispel Magic uses a dispel/resist setting of 1 for the VVC, which will cause a "Magic Resistance" message to pop up for chars with high MR. This, of course, afflicts every single spell and item they copied the effects to (probably 20 or so). Fun!

This is already fixed for the Dispel/Remove Magic spells, so went searching for other spells which might need fixing. Everything else either set the MR flag correctly or was target:self except for spin866 (FORCE_DISPEL_MAGIC) and Carsomyr's DM (sw2h10dm). They also have spurious MR checks for cure feeblemind and removal of the feeblemind icon, so those are now patched as well.

 

// some effects on dispel magic subject to MR, though all other effects are not
COPY_EXISTING ~spin866.spl~  ~override~ // FORCE_DISPEL_MAGIC
             ~sppr303.spl~  ~override~ // dispel magic (priest)
             ~spwi302.spl~  ~override~ // remove magic (mage)
             ~spwi326.spl~  ~override~ // dispel magic (mage)
             ~sw2h10dm.spl~ ~override~ // dispel magic (mage)
 READ_LONG  0x64 "abil_off"
 READ_SHORT 0x68 "abil_num"
 READ_LONG  0x6a "fx_off"
 FOR ("index" = 0; "%index%" < "%abil_num%"; "index" = ("%index%" + 1)) BEGIN // loop through abilities
   READ_SHORT  ("%abil_off%" + 0x1e + ("%index%" * 0x28)) "abil_fx_num"
   READ_SHORT  ("%abil_off%" + 0x20 + ("%index%" * 0x28)) "abil_fx_idx"
   FOR ("index2" = 0; "%index2%" < "%abil_fx_num%"; "index2" = ("%index2%" + 1)) BEGIN
     READ_SHORT ("%fx_off%" +        (0x30 * ("%abil_fx_idx%" + "%index2%"))) "opcode"
     PATCH_IF (("%opcode%" = 58) OR ("%opcode%" = 77) OR ("%opcode%" = 215) OR ("%opcode%" = 240)) BEGIN // dispel fx, cure fm, play 3d effect, remove icon opcodes
       WRITE_BYTE  ("%fx_off%" + 0x0d + (0x30 * ("%abil_fx_idx%" + "%index2%"))) 0 // no dispel/bypass MR
     END
   END
 END
 BUT_ONLY_IF_IT_CHANGES

Link to comment
This, of course, afflicts every single spell and item they copied the effects to (probably 20 or so). Fun!
That's where the real fun is, not all those unused spells that patch touches.

You're no fun.

 

// some effects on dispel magic subject to MR, though all other effects are not; see also sppr303 et al patch
COPY_EXISTING ~deva.itm~	 ~override~ // deva weapon
		  ~devaevil.itm~ ~override~ // deva weapon
		  ~elemchan.itm~ ~override~ // chan weapon
		  ~elemcryo.itm~ ~override~ // cryomix weapon
		  ~elemhydr.itm~ ~override~ // cryomix weapon
		  ~elemimix.itm~ ~override~ // imix weapon
		  ~elemogre.itm~ ~override~ // ogremoch weapon
		  ~elemsunn.itm~ ~override~ // sunnis weapon
		  ~elemyanc.itm~ ~override~ // yan-c-bin weapon
		  ~elemzaam.itm~ ~override~ // zaaman rul weapon
		  ~planetar.itm~ ~override~ // planetar weapon
		  ~ravag01.itm~  ~override~ // ravager weapon
 READ_LONG  0x64 "abil_off"
 READ_SHORT 0x68 "abil_num"
 READ_LONG  0x6a "fx_off"
 FOR ("index" = 0; "%index%" < "%abil_num%"; "index" = ("%index%" + 1)) BEGIN // loop through abilities
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
  READ_SHORT ("%fx_off%" +		(0x30 * ("%abil_fx_idx%" + "%index2%"))) "opcode"
  PATCH_IF (("%opcode%" = 58) OR ("%opcode%" = 77) OR	  // dispel fx, cure fm,
			OR ("%opcode%" = 215)("%opcode%" = 240)) BEGIN // play 3d effect, remove icon opcodes
	WRITE_BYTE  ("%fx_off%" + 0x0d + (0x30 * ("%abil_fx_idx%" + "%index2%"))) 0 // no dispel/bypass MR
  END
END
 END
 BUT_ONLY_IF_IT_CHANGES

Link to comment

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...