Neverwinter Nights 2
0 of 0

File information

Last updated

Original upload

Created by

Dann Pigdon

Uploaded by

DannJ

Virus scan

Safe to use

About this mod

Visual effects that put various items into a creature's hands without the need to spawn or equip items.

Permissions and credits
Visual effects that put various items into a creature's hands
without the need to spawn or equip items.

- fx_handl_stein (beer stein left hand - sitdrink animation)
- fx_handl_wine (wine bottle left hand - sitdrink animation)
- fx_handl_chalice (chalice left hand - sitdrink animation)
- fx_handr_stein (beer stein right hand - drink and beerdrink animations)
- fx_handr_wine (wine bottle right hand - drink and beerdrink animations)
- fx_handr_chalice (chalice right hand - drink and beerdrink animations)
- fx_handr_book (open book right hand - read and sitread animations)
- fx_handr_rake (*rake right hand - raking animation)
- fx_handr_spoon (spoon right hand - cooking01 animation)
- fx_handr_smithhammer (smith hammer right hand - craft or forge animation)

* The rake model in the game faces the wrong way. I have corrected this (and made
further tweaks) using Adinos's MDB Manipulation Tool. See the 'Files' section above.

Script examples for applying and removing the effects:

I tend to assign VFX to a spell ID, then use the
RemoveEffectsFromSpell function in nw_i0_spells to remove
the VFX without removing other spell effects.
I use the light spell, since its ID is easy to remember (100)
and it's not likely to be used by NPCs (and can't be cast on
hostile creatures).

The sVFX string can be changed as necessary to apply the
other VFX. It can also be stored as a local string variable
on a creature or usable item, for use in a generic script.


//Apply visual effect to creature
void main()
{
object oTarget = [insert function of choice]
string sVFX = "fx_handl_stein.sef";
//Assign VFX to spell id 100 (light spell)
effect eDrink = SetEffectSpellId(EffectNWN2SpecialEffectFile(sVFX), 100);
SetWeaponVisibility(oTarget, 0, 0);//Make weapons and shields invisible
ApplyEffectToObject(DURATION_TYPE_PERMANENT, eDrink, oTarget);
}

--
//Remove visual effect from creature
#include "nw_i0_spells"

void main()
{
object oTarget = [insert function of choice]
//Remove all effects linked to spell id 100 (light spell)
RemoveEffectsFromSpell(oTarget, 100);
SetWeaponVisibility(oTarget, 1, 0);//Make weapons and shields visible again
}