Jump to content

Abazigal's Shockwave


CamDawg

Recommended Posts

Something I discovered investigating the miscast magic icons... :p

 

For miscast magic effects, most spells have a pair of effects--for whatever reason, they have one effect that adds x% to spell failure, followed by a second that sets spell failure to x%. In the case of Abazigal's Shockwave, the spell first increases the miscast by 90% and then sets it to 0%. It should be setting it to 90%.

 

// abazigal's shockwave miscast effects
COPY_EXISTING ~spin531.spl~ ~override~
 READ_LONG  0x64 "abil_off" ELSE 0
 READ_SHORT 0x68 "abil_num" ELSE 0
 READ_LONG  0x6a "fx_off" ELSE 0
 FOR (index = 0; index < abil_num; index = index + 1) BEGIN
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 * ("%abil_fx_idx%" + "%index2%"))) "opcode"
  PATCH_IF ("%opcode%" = 60) BEGIN // if miscast magic
	WRITE_LONG ("%fx_off%" + 0x04 + (0x30 * ("%abil_fx_idx%" + "%index2%"))) 90
  END
END
 END
 BUT_ONLY_IF_IT_CHANGES

Link to comment

Remember, these are spell types. IIRC, it was setting mage to 90% and priest to 0%. I think the hive mother anti-magic ray also did this. I'm not sure if it's intentional; these would be the only 2 spells that don't give equal failure for both spell types.

 

ABZAWAY - this was copied from the normal wing buffet, but they forget to change one of the target types from preset to the new target type (I think it was the damage opcode).

Link to comment

Ah, I shoulda checked the IESDP. NI identifies these as Inc/Dec (0) and Set (1) instead of spell type. I can't imagine it's intentional; it's essentially wiping out any miscast effects for divine spells that may be present. Unless they're all cumulative instead of setting absolute values, in which case we should ask why they didn't delete the effect outright.

Link to comment

The Anti-Magic Rays of hive mothers have the same issue--even normal beholder anti-magic rays set divine miscast penalties.

 

// hive mother anti-magic ray not affecting divine spellcasting
COPY_EXISTING ~spin550.spl~ ~override~
 READ_LONG  0x64 "abil_off" ELSE 0
 READ_SHORT 0x68 "abil_num" ELSE 0
 READ_LONG  0x6a "fx_off" ELSE 0
 FOR (index = 0; index < abil_num; index = index + 1) BEGIN
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 * ("%abil_fx_idx%" + "%index2%"))) "opcode"
  PATCH_IF ("%opcode%" = 60) BEGIN // if miscast magic
	WRITE_LONG ("%fx_off%" + 0x04 + (0x30 * ("%abil_fx_idx%" + "%index2%"))) 100
  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...