Skip to content

New Opcode: Ability Drain

RaduzielRaduziel Member Posts: 4,714
edited February 2019 in Feature Requests
Hi.

Right now, abilities drain is handled using the same Opcode that increases the attributes.

The problem: by PnP, there should exist several ways to prevent ability score draining from, let's say a shadow. And many creatures should be immune to it. None of those can be properly translated to IE because blocking the ability drain also blocks the ability buff. So the same effect that protects against the shadow attack also blocks Champion's Strength.

The solution:

Opcode X

P1: Ability (0 - All, 1 - Str, 2 - Dex, 3 - Con, 4 - Int, 5 - Wis, 6 - Cha)

P2: Value (this Opcode accepts positives values only)

Special: (0 - Only Drain, 1 - Drain to Caster).

---

Now a shadow attack can be blocked through Opcode 101 using parameter X.

Undead may have their scores preserved through Opcode 324.

Everyone is happier.

Comments

  • RaduzielRaduziel Member Posts: 4,714
    I'll call @CamDawg @kjeron @Bubb @argent77 @subtledoctor as I would like their opinion about this.
  • OlvynChuruOlvynChuru Member Posts: 3,079
    One thing you could do is use the disease opcode, which also lets you lower a creature's attributes.
  • RaduzielRaduziel Member Posts: 4,714
    edited February 2019
    OlvynChuru wrote: »
    One thing you could do is use the disease opcode, which also lets you lower a creature's attributes.

    This just shifts the problem from one place to another: a Paladin is immune to Disease, but shouldn't be immune to ability score drain.
  • kjeronkjeron Member Posts: 2,368
    Put all drain effects into EFF files, set parent type(0x90) to spell(1), assigning a common parent resref(0x94) "ABDRAIN".
    Use opcode 206/318 to provide immunity to that resref "ABDRAIN".
  • RaduzielRaduziel Member Posts: 4,714
    edited February 2019
    kjeron wrote: »
    Put all drain effects into EFF files, set parent type(0x90) to spell(1), assigning a common parent resref(0x94) "ABDRAIN".
    Use opcode 206/318 to provide immunity to that resref "ABDRAIN".

    That is a solution, but demands a modded game.

    I'm talking about using this new feature as vanilla in things like Negative Plan Protection or Enrage etc.

    And also I think that the plain Opcode would make life easier for modders. Checking IESDP I saw several opcodes labeled as "Unused" (like #322, #364 and everything between #347 and #359) that's why I had this idea.

    Is there something I'm not considering?

    Thanks!
  • The user and all related content has been deleted.
  • kjeronkjeron Member Posts: 2,368
    Also: why in my head did I think opcode 101 had a field that was something like "match parameter2" for more fine-grained immunity? I just looked at it and it's not there... so what am I thinking of?
    Opcode 337 - Remove: Limited Effects (by Opcode)
  • RaduzielRaduziel Member Posts: 4,714
    @subtledoctor It could make some creatures and spells act like they should.

    And I also believe that it would open new horizons for modding spells and kits in a simpler and less invasive way (modding compatibility, I mean).

    I don't know a better place to leave suggestions for Beamdog, unfortunately.
  • The user and all related content has been deleted.
  • RaduzielRaduziel Member Posts: 4,714
    edited February 2019
    @subtledoctor Thanks, I'll request there too.

    Edit: Feature 40172 created.

    https://support.baldursgate.com/issues/40172
  • switswit Member, Translator (NDA) Posts: 495
    edited March 2019
    Raduziel wrote: »
    kjeron wrote: »
    Put all drain effects into EFF files, set parent type(0x90) to spell(1), assigning a common parent resref(0x94) "ABDRAIN".
    Use opcode 206/318 to provide immunity to that resref "ABDRAIN".

    That is a solution, but demands a modded game.

    I'm talking about using this new feature as vanilla in things like Negative Plan Protection or Enrage etc.

    And also I think that the plain Opcode would make life easier for modders. Checking IESDP I saw several opcodes labeled as "Unused" (like #322, #364 and everything between #347 and #359) that's why I had this idea.

    Is there something I'm not considering?

    Thanks!
    I agree that it would be nice to have such feature being part of the vanilla game system, if that's what PnP says, but the requested dedicated opcode for it seems redundant. Solution posted by kjeron does the same thing and is relatively easy to implement - pretty much the same amount of work as writing weidu code that automatically replaces one opcode depending on parameter value with another, which would be needed anyway to mod-in your suggestion (I can't think about a single feature request like this fulfilled by Beamdog, so it's either done by mod or won't be there at all).
    Post edited by swit on
  • RaduzielRaduziel Member Posts: 4,714
    @swit

    Stop crushing my dreams. What did I do to you?

    Kidding.

    I don't have any hope that Beamdog will implement this (or any of this TBH), my bet is on Bubb's new alien tech.
Sign In or Register to comment.