[RELz] NifSE v1.1

Post » Tue Dec 13, 2011 3:39 pm

NifSE is an OBSE plug-in that allows Oblivion script to operate on Nif files during run-time. Nif files, or NetImmerse Format files, are 3D meshes which are used by Oblivion. These files have long been editable with 3D software and NifTools' excellent NifSkope utility, but certain operations on Nif files have been desirable for scripters and therefore impossible - until now.

More specifically, NifSE uses the NifTools' incredible "C++ library for loading, modifying, and exporting NIF files," NifLib, to create new functions through OBSE's plug-in API. Much thanks to both the OBSE and NifTools teams for their hard work that has made this possible.

For v1.0 we have a staggering number of new functions, plus an entirely new backbone system for storing, manipulating, and saving nif files. There is no more hard-drive bloat, as the nif files are only very briefly written to disk for Oblivion to read when it needs them, and deleted again as soon as it is finished. Nifs are saved in the .obse co-save file, and recreated as needed. The old functions are both now considered deprecated (as is the undocumented function NifGetBackShield, which was never supported in the first place), but backwards compatibility has been maintained, and the old functions have been somewhat updated to use the new system and therefore no longer clutter the user's harddrive.

Downloads
  • http://tesalliance.org/forums/index.php?/files/file/917-nifse/ (NifSE v1.1, v1.0 example plugin)
  • http://tesnexus.com/downloads/file.php?id=21292 (NifSE v1.1, v1.0 example plugin)
  • http://code.google.com/p/nifse/ (NifSE v1.1, v1.0 example plugin, source code)


Changelog (v1.1)
  • Fixed crash if a BSA has a '%' in the filename.
  • See NifSE changelog.txt included in download archive


Known Bugs (v1.1)
  • A bug in Niflib prevents it from correctly writing Skin Partition Blocks (an important part of rigged meshes, such as clothing or armor) that use strips instead of triangles. Amorillia of the NifTools team and I are working on this.
  • A bug in NiNodeCopyChild causes it to fail when the desired branch-to-copy contains references to blocks outside of the branch. This happens most often with skins (these skins seem to be the bane of NifSE's existence; they also caused the infamous sheathe-bug that caused problems from the first version of NifScript), which again, are an important part of rigged meshes.
    • As a result of these two bugs, NifSE should not be used on rigged meshes. A bugfix v1.2 will be available ASAP to fix these bugs. Unfortunately, this will require modifications to Niflib that I cannot do myself.

  • Beta 3 broke backwards-compatibility with functions that take arrays as arguments; these must now be compiled using OBSE v0020's compiler override. This means mods that were designed for beta 2 will not work, though only a little effort should be necessary to make them work. For this reason,
    • To use Deadly Reflex 6, you must use the http://www.tesnexus.com/downloads/file.php?id=40336.


To Do List (roughly in order of when each is most likely to be implemented)
  • Future versions
    • Functions for working with collision blocks themselves.
    • Get/Set Vertex colors
    • Get/Set UV coordinates
    • Animations


Please post any ideas you have for the utility here!
User avatar
Miss Hayley
 
Posts: 3414
Joined: Tue Jun 27, 2006 2:31 am

Post » Tue Dec 13, 2011 12:02 pm

Woehoew! :celebrate:
User avatar
Ally Chimienti
 
Posts: 3409
Joined: Fri Jan 19, 2007 6:53 am

Post » Tue Dec 13, 2011 5:55 pm

Indeed, I'm pretty pleased by it. Now if only DR6 used it...
User avatar
Abel Vazquez
 
Posts: 3334
Joined: Tue Aug 14, 2007 12:25 am

Post » Tue Dec 13, 2011 6:06 am

Huzzah :celebration:
User avatar
Queen
 
Posts: 3480
Joined: Fri Dec 29, 2006 1:00 pm

Post » Tue Dec 13, 2011 2:46 pm

Ahhh NifSE.....its been a while since I last checked on you. :turned:

Great to see it at v1.0! Im really looking forward to getting back into using it during my winter break at the moment,,,,but Im wondering if there are any newer more up to date tutorials...or even just other scripts I can look at for using it.



PS: THis topic needs more attention! NifSE is amazing!
User avatar
Isaac Saetern
 
Posts: 3432
Joined: Mon Jun 25, 2007 6:46 pm

Post » Tue Dec 13, 2011 6:40 pm

Awesome, that makes me really excited. I haven't scripted for Oblvion in so long, though, I hope I'll be able to remember enough to get back into it quickly. And I hacked my way around that script and I had so many different ways to try and make this work before I gave up on it not being possible--so hopefully the code I had is readable/usable..

Ok, knowing this, one more question. Awesome Sword 1 and Awesome Sword 2 (as1 and as2) have the same mesh / texture. Let's say I put as1 into my container, I copy its mesh onto a dummy object and remove the collision so it'll rotate above the container. While as1 is still in the container, I pull out as2, will only the copy of as1 floating above the container have the collision removed or will everything that uses that mesh have the collision removed. If not, is there some way to make an isolated copy of that mesh so it doesn't interfere with other things that share that same mesh?

NifSE does not modify any meshes ever. Very important. You must use NifGetPath to get the path of the "virtual NIF" that NifSE creates, and use SetModelPath (or whatever) to apply it. It would not affect as1 or as2 unless and until you use SetModelPath to change their model to NifSE's virtual model.
User avatar
Laura Cartwright
 
Posts: 3483
Joined: Mon Sep 25, 2006 6:12 pm

Post » Tue Dec 13, 2011 7:28 am

NifSE does not modify any meshes ever. Very important. You must use NifGetPath to get the path of the "virtual NIF" that NifSE creates, and use SetModelPath (or whatever) to apply it. It would not affect as1 or as2 unless and until you use SetModelPath to change their model to NifSE's virtual model.

Great, that's the best answer I could've hoped for.
User avatar
Sweet Blighty
 
Posts: 3423
Joined: Wed Jun 21, 2006 6:39 am

Post » Tue Dec 13, 2011 12:33 pm

Congratulations on the milestone! :D
User avatar
Jimmie Allen
 
Posts: 3358
Joined: Sun Oct 14, 2007 6:39 am

Post » Tue Dec 13, 2011 11:15 am

Great, that's the best answer I could've hoped for.

Glad to hear it!

Congratulations on the milestone! :D

Thanks!
User avatar
Louise Dennis
 
Posts: 3489
Joined: Fri Mar 02, 2007 9:23 pm

Post » Tue Dec 13, 2011 1:52 pm

NifSE has been updated to v1.1: it will no longer crash if a BSA has a '%' in the filename (which it did before). Many thanks to roxarhis for finding this.

Since a few have asked: v1.1 is fully backwards-compatible, i.e. it works with anything that works with v1.0. The change between the two is really minor, actually, and affects almost-nothing: the crash was caused by the code that prints out the list of BSAs to NifSE.log. I.e. absolutely nothing of major importance.
User avatar
Sheila Esmailka
 
Posts: 3404
Joined: Wed Aug 22, 2007 2:31 am


Return to IV - Oblivion