Skip to content

Commit

Permalink
[bg, bg2, iwd] Dueling fireshields don't go infinite
Browse files Browse the repository at this point in the history
Part 5 of X of Cam incorporating fixes from jmerry's Tweaks and Fixes (with permission). Based on updated version posted here:

https://www.gibberlings3.net/forums/topic/34941-bug-spotted-on-reddit-hallowed-redeemer-vs-fire-shield/#comment-309407
  • Loading branch information
CamDawg committed Jul 29, 2022
1 parent 97fa7fa commit ef73ab8
Show file tree
Hide file tree
Showing 4 changed files with 38 additions and 0 deletions.
4 changes: 4 additions & 0 deletions eefixpack/files/tph/bg2ee.tph
Expand Up @@ -637,6 +637,10 @@ END
// simulacrum/projected images should have thief skills, but no shadow twin
INCLUDE ~eefixpack/files/tph/tbd_simulacrum.tph~

// tbd, cam (from jmerry)
// prevent infinite feedback (and resultant crash) from interacting fireshield-ish effects by giving them a brief immunity to re-application
INCLUDE ~eefixpack/files/tph/tbd_fireshields.tph~

// luke
// **Cure Wounds**
WITH_SCOPE BEGIN
Expand Down
4 changes: 4 additions & 0 deletions eefixpack/files/tph/bgee.tph
Expand Up @@ -941,6 +941,10 @@ END
// simulacrum/projected images should have thief skills, but no shadow twin
INCLUDE ~eefixpack/files/tph/tbd_simulacrum.tph~

// tbd, cam (from jmerry)
// prevent infinite feedback (and resultant crash) from interacting fireshield-ish effects by giving them a brief immunity to re-application
INCLUDE ~eefixpack/files/tph/tbd_fireshields.tph~

// luke
// **Cure Wounds**
WITH_SCOPE BEGIN
Expand Down
4 changes: 4 additions & 0 deletions eefixpack/files/tph/iwdee.tph
Expand Up @@ -572,6 +572,10 @@ END
INCLUDE ~eefixpack/files/tph/5919_iwdee_spider_spawn.tph~ // ie-5919, cam: spider spawn only summons giant spiders, should also summon phase and sword
INCLUDE ~eefixpack/files/tph/tbd_simulacrum.tph~ // tbd, cam (from jmerry): simulacrum/projected images should have thief skills, but no shadow twin

// tbd, cam (from jmerry)
// prevent infinite feedback (and resultant crash) from interacting fireshield-ish effects by giving them a brief immunity to re-application
INCLUDE ~eefixpack/files/tph/tbd_fireshields.tph~

// tbd, davidw
// circle of bone subspell has illegal character in sig
COPY_EXISTING "#bonecir.spl" override WRITE_ASCII 0x0 "SPL "
Expand Down
26 changes: 26 additions & 0 deletions eefixpack/files/tph/tbd_fireshields.tph
@@ -0,0 +1,26 @@
// tbd, cam (from jmerry)
// prevent infinite feedback (and resultant crash) from interacting fireshield-ish effects by giving them a brief immunity to re-application
ACTION_DEFINE_ASSOCIATIVE_ARRAY cd_fireshields BEGIN
~balshld2~ => 0 // [bg2] balshld.spl (unused)
~bdbarbde~ => 0 // [bg] bdhamat2.itm: Hamatula item (barbed defense)
~bdsha12a~ => 0 // [multi] bgsha12a/bdsha18a.itm: shaman summons, (lesser) fire spirit
~bdshld02~ => 0 // [bg] bdhsld02.itm: The Suncatcher feedback
~keldorn~ => 0 // [multi] npswo03.itm: Hallowed Redeemer
~leat23a~ => 0 // [multi] leat23.itm: Studded Leather of Thorns +6 [original power 4]
~spcl237d~ => 0 // [multi] spcl237.spl: Greater Sun [original power 4]
~spimixd~ => 0 // [multi] elemimix/elemzaam.itm: Imix/Zaaman Ruul fireshield [original power 4]
~sppr730d~ => 7 // [multi] sppr730.spl: auro o' flaming death [original power 4]
~sppr951d~ => 0 // [multi] unused, fix anyway
~sppr952d~ => 0 // [multi] unused, fix anyway [original power 4]
~spwi403d~ => 4 // [multi] spwi403.spl: fire shield blue
~spwi418d~ => 4 // [multi] spwi418.spl: fire shield red
END

ACTION_PHP_EACH cd_fireshields AS spell => pow BEGIN

COPY_EXISTING ~%spell%.spl~ ~override~
LPF ALTER_EFFECT INT_VAR match_opcode = 12 power = pow END
LPF CLONE_EFFECT INT_VAR match_opcode = 12 opcode = 206 parameter1 = 0 timing = 10 duration = 2 STR_VAR insert = last resource = EVAL ~%SOURCE_RES%~ END // clone damage into 2 ticks of immunity
BUT_ONLY IF_EXISTS

END

0 comments on commit ef73ab8

Please sign in to comment.