Jump to content

Resist Fire/Cold has incorretc duration


CamDawg

Recommended Posts

The level 20 version of this spell has an incorrect duration at level 20 of 200 seconds, should be 120. The bug where it can stack with itself is already covered in another patch.

 

// resist fire/cold has incorrect duration at level 20; stacking issue already covered below
COPY_EXISTING ~sppr210.spl~ ~override~
 READ_LONG  0x64 "abil_off"
 READ_SHORT 0x68 "abil_num"
 READ_LONG  0x6a "fx_off"
 PATCH_IF ("%abil_num%" > 0) BEGIN // grabs last ability (lev 20)
   READ_SHORT ("%abil_off%" + 0x1e + (("%abil_num%" - 1) * 0x28)) "abil_fx_num"
   READ_SHORT ("%abil_off%" + 0x20 + (("%abil_num%" - 1) * 0x28)) "abil_fx_idx"
   WHILE ("%abil_fx_num%" > 0) BEGIN
     SET "abil_fx_num" = ("%abil_fx_num%" - 1)
     READ_LONG ("%fx_off%" + 0x0e + (0x30 * ("%abil_fx_idx%" + "%abil_fx_num%"))) "duration"
     PATCH_IF ("%duration%" = 200) BEGIN // incorrect duration
       WRITE_LONG ("%fx_off%" + 0x0e + (0x30 * ("%abil_fx_idx%" + "%abil_fx_num%"))) 120 // corrects duration
     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...