As far as reusing the original game's spell effects: The bad news is that Niftools can't properly import the original files, so you can't count on it to reexport as xnif + kf, The good news is that Nifskope can be used to cut a full NIF (geometry + animation) into KF (keyframe data only, with parent information added into NiStringExtraData) + xNIF (NIF with keyframe data removed). Attached KFTEST example, cut out of the "absorb" effect, works ingame (PlaceAtMe KFTEST 1 1 1). What I don't know yet is how this works if the NIF file has several elements with different keyframe controllers on each.
Does it work? yes, am I quite sure why? no. To convert an original spell effect into an activator like this, find the mesh from Gameplay>Magic effects then the Statics tab or in the /e/ folder. Add KeyFrameController data (contains Idle: Start, Idle: Stop...) in Nifskope. Then save; delete all keyframe data and save into a x.NIF; manually create a x.KF file by removing everything else instead (you need to reorder and create NiStringExtraData with the object names for each controller). That's a lot of manual work needed so doing it by default to all available spell effects isn't likely to happen, and a /e/ folder and _Vfx_ ID type won't be useful in the short term.
Benefits: - visual effect without spell damage, aggression - no need for hacks with invisible NPCs or objects exploding spells on themselves - instant placement, place and forget, no casting time - could edit the mesh keyframes to make magic effects that loop instead - use custom textures for different visuals
I think this could probably be automated via PyFFI; I was trying to put together a script for building .kf files the other month, so I'll see if I can jury-rig something together out of it.
edit: I've done some PyFFI-prodding and uploaded the result; a few spell effects (hand01, lightningbolts, cast_ill, cast_levitate, hit_levitate) don't have keyframe controllers, so I didn't include them. Additionally, the blight and hit_myst effects have negative start times, so their animations won't play in MW (OpenMW plays them fine, however).
Likely this will need some thorough testing; some effects don't display right for me but that might just be a problem on my (linux) end.
Just converted the levitate effect for a mod so I've uploaded it here: magic_hit_Levitate.nif NiUVController animation, doesn't use keyframes so xNIF and xKF files aren't needed. Made it work with nifskope by editing the type of each "NiNode" into "NiBSAnimationNode" and changing the "Flags" on each from 10 to 42, though the rings aren't always synchronous ingame (edit: you can just add 64 to flags to remove random time)
Comments
As far as reusing the
As far as reusing the original game's spell effects:
The bad news is that Niftools can't properly import the original files, so you can't count on it to reexport as xnif + kf,
The good news is that Nifskope can be used to cut a full NIF (geometry + animation) into KF (keyframe data only, with parent information added into NiStringExtraData) + xNIF (NIF with keyframe data removed). Attached KFTEST example, cut out of the "absorb" effect, works ingame (PlaceAtMe KFTEST 1 1 1). What I don't know yet is how this works if the NIF file has several elements with different keyframe controllers on each.
Added the shock (lightning
Added the shock (lightning area) effect.
Does it work? yes, am I quite sure why? no. To convert an original spell effect into an activator like this, find the mesh from Gameplay>Magic effects then the Statics tab or in the /e/ folder. Add KeyFrameController data (contains Idle: Start, Idle: Stop...) in Nifskope. Then save; delete all keyframe data and save into a x.NIF; manually create a x.KF file by removing everything else instead (you need to reorder and create NiStringExtraData with the object names for each controller). That's a lot of manual work needed so doing it by default to all available spell effects isn't likely to happen, and a /e/ folder and _Vfx_ ID type won't be useful in the short term.
Benefits:
- visual effect without spell damage, aggression
- no need for hacks with invisible NPCs or objects exploding spells on themselves
- instant placement, place and forget, no casting time
- could edit the mesh keyframes to make magic effects that loop instead
- use custom textures for different visuals
I think this could probably
I think this could probably be automated via PyFFI; I was trying to put together a script for building .kf files the other month, so I'll see if I can jury-rig something together out of it.
edit: I've done some PyFFI-prodding and uploaded the result; a few spell effects (hand01, lightningbolts, cast_ill, cast_levitate, hit_levitate) don't have keyframe controllers, so I didn't include them. Additionally, the blight and hit_myst effects have negative start times, so their animations won't play in MW (OpenMW plays them fine, however).
Likely this will need some thorough testing; some effects don't display right for me but that might just be a problem on my (linux) end.
Just converted the levitate
Just converted the levitate effect for a mod so I've uploaded it here: magic_hit_Levitate.nif
NiUVController animation, doesn't use keyframes so xNIF and xKF files aren't needed. Made it work with nifskope by editing the type of each "NiNode" into "NiBSAnimationNode" and changing the "Flags" on each from 10 to 42, though the rings aren't always synchronous ingame (edit: you can just add 64 to flags to remove random time)
The summon and interventions
The summon and interventions effect is already merged in data v7