Skip to content

Project Images/Simulacra shouldn't cast these spells

GalactygonGalactygon Member, Developer Posts: 412
edited September 2014 in BGII:EE Bugs (v1.2.2030)
Existing behavior: There are certain spells that projected images/simulacra may cast but otherwise do nothing. Also, both projected images and simulacra are able to cast simulacrum (thereby creating a copy of a copy), which enables many different exploits.

Expected behavior: Certain spells should simply not be castable, preferrably not even selectable from projected images/simulacra.

How to reproduce this: have a spellcaster created by simulacrum cast project image. Or a caster created by project image/simulacrum cast simulacrum. They could also attempt any trigger/contingency spells except no spell icons will show up.

Suggested implementation: Remove a certain list of spells via instances of effects in PROJIMAG.spl and SIMULACR.spl. This will require instances of opcode 172 to remove the following spells:
SPWI420 (Minor Sequencer)
SPWI420D
SPWI420P
SPWI607 (Mislead)
SPWI617 (Contingency)
SPWI703 (Project Image)
SPWI710 (Spell Sequencer)
SPWI710D
SPWI710P
SPWI804 (Simulacrum)
SPWI809 (Spell Trigger)
SPWI809D
SPWI809P
SPWI908 (Chain Contingency)
Also, it will be necessary to remove the following:
SPIN150 - SPIN157 (Shapechange subspells)
SPWI489 - SPWI499 (Polymorph Self subspells)

Note: opcode 172 functions at the moment as an "unmemorize one copy" effect unless one spell is memorized in which case it unmemorizes one copy and removes the spell from the spell book. You might need many instances of this effect for each spell (like 5 just in case).
Note2: If opcode 172 can be expanded to be able to "unmemorize" multiple copies in one go (with params 1 or 2) then that would be fantastic. This is somewhat relevant to this thread concerning 172: http://forum.baldursgate.com/discussion/35033/known-9861-creature-files-overriding-memorized-spells

EDIT: To clarify why removing shapechage/polymorph spells is a good idea is simply that they act as "temporary" spells which appear and disappear at duration end. However, as "temporary" spells, they are copied to the project image/simulacrum unlike temporary effects (with duration/delay) which are not copied.
Post edited by Galactygon on

Comments

  • kjeronkjeron Member Posts: 2,368
    Actually, Opcode 172 can unmemorize all copies. However, It's effect is filename length dependent. Adding it to PROJIMAG works and will correctly remove all copies of any spell with a less than full filename length: 7 characters or less. All learn-able vanilla spells meet this requirement. Filenames with a length of 8 characters can only be removed one at a time, and memorizations only if already cast.

    Sequencer subspells (D&P) inherited from the caster currently can not, but need not, be removed - the Image/Simi will not have any spells in the sequencer to activate. They only need not be able to cast the Sequencer/Contingency base spell.
  • GalactygonGalactygon Member, Developer Posts: 412
    @Kjeron Thanks for the details on 172. I've replied in the other thread:
    http://forum.baldursgate.com/discussion/comment/554158/#Comment_554158

    It seems the "P" sequencer subspells are not used in the game, even when I tried to load the sequencers with "cast spell at point" type spells. I can open a new thread on this @Gate70 . Some of the rest is aesthetical - you know you cannot inherit sequencers as an image/simulacrum, so why have it appear in the innate abilities? It just gives an unpolished feel to it.
  • Gate70Gate70 Member, Developer Posts: 3,883
    I'd like to check details here please.

    1. Simulacrum casting Shapechange or Simulacrum casting Polymorph self.
    * I believe you are saying these spells do nothing. i.e. F12 produces no forms.
    * Try selecting your character, then the simulacrum, then F12 again.
    * I could get both variants to work like this. Might want to raise a bug to see why re-select is required?

    2. Simulacrum casting Project Image or Simulacrum casting Simulacrum.
    * I believe you are saying this is an exploit.
    *This might be a feature request rather than a bug.

    3. Simulacrums using previously memorised sequencers.
    * Agree, the simulacrum can access special ability menu, select the sequencer, and nothing happens.

    Thanks
  • GalactygonGalactygon Member, Developer Posts: 412
    1. What I meant was if the caster has already casted shapechange or any other spell that grants an innate ability, then that ability is inherited by the project image/simulacrum for free. For example if you cast shapechange first and then project image/simulacrum, either copy of the caster may assume any polymorphed forms because the innate abilities are copied (even though they shouldn't). This is a bug because there is not way for the engine to detect whether an innate ability is temporarily granted or permanent. Carried effects on the other hand are not carried if they have a duration/delay attached to them.

    This workaround simply removes all of those temporarily granted innate abilities, so I might have missed a couple in the above list.

    2. Yes, it's more of an exploit, to which the fix seems pretty easy (a couple of remove spell effects)
Sign In or Register to comment.