Nwn2fixes


#183

Forbidden spells
#184

Nvm.


#185

Passing an integer value of from 2 to 9 to the ItemPropertyImmunityToSpell(nLevel) call will set its GetItemPropertyCostTableValue(iprop) returned value to nLevel-1. Passing an nLevel value of ‘1’ will result in an invalid cost table value result of ‘-1’. Basically it looks like you can’t make something immune to only 1st level spells. There’s probably no way to fix this though.

I suspect level 1 was disabled since an nLevel of 1 would result in a cost of 0. But that seems dumb; why not fix it to use nLevel? Ah well.


#186

interesting, Rj

i’ll have a look myself when time permits,

Are you sure there isn’t an item (stock) that grants immunity to 1st level spells like Magic Missile? …


#187

There’s an item property call to add immunity to specific spells. Is that what you mean?

It might be that the toolset works differently. I was just working with the script calls.


#188

in the toolset there’s an AvailableProperty “Immunity: Spells by Level”

in its CostValue dropdown are the following:

NONE
Level 1 or Lower
Level 2 or Lower
Level 3 or Lower
Level 4 or Lower
Level 5 or Lower
Level 6 or Lower
Level 7 or Lower
Level 8 or Lower
Level 9 or Lower
Random

requires tinkering to figure out what’s going on tho.

 
as far as i’m aware any IP that can be scripted can be set on an item in the toolset, and vice versa


#189

The ItemPropertyDamageReduction function seems to be messed up, or at least the toolset documentation is incorrect. It is unclear what goes in the nDRSubType field, for example. The documentation says something about an nDmgBonus field, but there’s non-such in the function definition. I tried putting in various values, but I just end up with an invalid itemproperty.


#190

DamageReduction isn’t an IP anymore. It doesn’t script as an itemproperty (although as an effect it scripts fine)

the only way, apparently, to apply the DamageReduction property to an item is with the toolset.

point is, it’s not an IP anymore – it’s its own beast in Nwn2 – so the function that was used to apply it is obsolete.

 
Edit: changed “work” to (verb) “script”