nwn2fixes / player

Fixes for the casual NwN2 player
27 stars 11 forks source link

SOZ : Hold monster does not appear to work #23

Open Question2 opened 5 years ago

Question2 commented 5 years ago

nwn8

Despite failing the will save, the fell troll could keep attacking without being held.

Question2 commented 5 years ago

Just realised that the weird spell issues im seeing may be due to reeron's spell fixes pack being merged with kaedrin's pack. Going to do some more testing after cleaning out the script folder.

kevL commented 5 years ago

in this case, Hold Monster doesn't stick to trolls because trolls have their Immortal flag set TRUE. They need to be immortal so their "killed only by acid or fire" mechanic works properly. The fact that EFFECT_TYPE_PARALYSIS does not stick to Immortal creatures is handled by the engine (ie, is hardcoded).

there are workarounds but I'm not sure i want to touch it atm. Basically, consider trolls immune to hold/paralysis until further notice

I want to try a) temporarily clearing the Immortal flag, stick the paralysis, then re-apply the immortal flag and see if paralysis still holds. b) the paralysis effect could be replace with the cutscene-paralysis effect – but the latter doesn't do a "save every turn" check like ordinary paralysis does, so a pseudo-heartbeat would have to run with a simulated saving throw ... not pretty. c) any change to Hold Monster should be done to all other spellscripts etc that use the paralysis effect – which is even less pretty

So atm am thinking "trolls are immune to Hold Monster" etc.

kevL commented 5 years ago

this seems to work (after the Will save in 'nw_s0_holdmon')

    int bImmortal = GetImmortal(oTarget);
    SetImmortal(oTarget, FALSE);
    if (bImmortal)
        DelayCommand(0.f, SetImmortal(oTarget, TRUE));