Jump to content

Remove effects of custom spell


Recommended Posts

Posted

I've created new spells which work as intended in-game. Some of those spells have status effects which if I use "Protection from spell (206)", it protects the caster from such effects. Now I want to create another spell which removes the same status effects if a target is suffering from it.

I've tried using "Remove spell (172)" and "Remove effects by resource (321)" with the following main properties but it doesn't work:

- Timing mode - Instant/Permanent until death - 1

- Dispel/Resistance - Not dispel/Bypass resistance (2)

- Duration - 0

- Probability 1 - 100

Any suggestions

Posted
18 minutes ago, subtledoctor said:

Opcode 321 should do it. You need to specify the first custom spell in the ‘resource’ field. 

EDIT - you might have the probability wrong. First prob field = 100, second = 0. 

Doh, you're right as usual. I set the first prob field to 0 and the second to 100. Now it works great. I blame Friday night...

Many thanks!

Posted

What's opcode 172 for, then? It removes a spell from a creature's list of known spells, and all instances of it being memorized by that creature. For example, natural form abilities use this to remove the temporary abilities certain forms get (salamander fireballs, mind flayer psionic blasts).

Posted
14 hours ago, jmerry said:

What's opcode 172 for, then? It removes a spell from a creature's list of known spells, and all instances of it being memorized by that creature. For example, natural form abilities use this to remove the temporary abilities certain forms get (salamander fireballs, mind flayer psionic blasts).

Ahhh that makes sense. Thanks for the description, I can certainly use this for some scenarios.

I really need to start using the documented resources (https://gibberlings3.github.io/iesdp/opcodes/bg2tob.htm#op172)

Join the conversation

You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...