NifScript allows scripters to edit Nif files during run-time. Currently, it only has two functions, but I'm interested in adding more. Feedback is massively appreciated: any scripters who would like certain features, let me know. I don't honestly know what the most useful things to have would be. But if there is anything you can do in NifSkope that you would like to do dynamically, this is the place to ask!
- an OBSE plug-in by DragoonWraith
2. Requirements
3. Installation
3b. Upgrading
4. Proof of Concept
5. Warning
6. Plans
7. Contact
8. Credits
== Introduction ==
NifScript 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, NifScript 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.
NifScript is only just getting started, and currently only has two highly-specialized functions. These functions are beta-only. They have been tested, but will be replaced in the next version. Please do not release any plug-ins using these functions as anything other than a Beta, and please be prepared to switch to the new system when the next version of NifScript becomes available.
- (string_var:path) [reference.]NifGetAltGrip [ref:weapon]
- Returns the path (relative to Oblivion\Data\Meshes) to a version of a weapon's nif that uses the opposite number of hands (two-handed to one-handed and vice versa)
- (string_var:path) [reference.]NifGetOffHand [ref:weapon]
- Returns the path (relative to Oblivion\Data\Meshes) to a version of a weapon's nif that is set-up to be used as a Shield item, using the weapon to parry attacks
== Requirements ==
- http://obse.silverlock.org/
OBSE goes in the Oblivion\ folder, not the Oblivion\Data folder like most mods. Please see OBSE's readme for
details. Remember to always start Oblivion using obse_loader.exe when using OBSE.
== Installation ==
With OBMM:
Without OBMM:
For more on installing and using mods, see Dev_akm's http://cs.elderscrolls.com/constwiki/index.php/Oblivion_Mods_FAQ
=== Upgrading ===
Special notes to all of those who used previous versions of NifScript:
To do so, you should create a clean save game: open your game, make sure you have no weapons that have been altered by NifScript (switching back from off-hand or alt-grip versions will give you the original weapons), and Save. Exit the game, and deactivate the Proof of Concept mod. Load your game, say OK to the warning, and Save again. Now go back, install the new version, and continue to play from there.
== Proof of Concept ==
I have removed the Proof of Concept mod. If you have been using it, please remove it (see 3b. about upgrading). If you are looking for a mod with which to use NifScript, I heartily recommend HeX_0ff's Unnecessary Violence, which can be found at TES Nexus.
== Warning ==
This utility creates new files. These do take space on your hard drive.
Included is a Windows Batch file which will delete Nif's altered by NifScript from your hard drive. To use it, simply double-click on the file, and it will remove the files. It does so blindly, it does not know whether or not that file is still needed. Essentially, this cannot be used accept to cleanly removed NifScript from your computer. If you use this Batch file when a save game still needs one of those files, you will get missing mesh icons.
== Plans ==
NifScript has only just gotten started. There are a ton of features enabled by NifLib that could be exposed to Oblivion's script language. Almost anything you can do in NifSkope, could be done by script.
I am currently working on a better file-handling system for NifScript. This should limit, or even eliminate the number of files created by the utility. The functions extant in this version of NifScript will become deprecated in the next version. They will be replaced by a cleaner system.
Any other requests are welcome. Please find the NifScript thread on the Elder Scrolls Forums, and offer feedback and requests.
== Contact ==
The preferred method of contacting me is a PM on the official Elder Scrolls Forums. My user-name is DragoonWraith.
The ESF thread for NifScript (as of this upload) can be found here: http://www.gamesas.com/bgsforums/index.php?showtopic=922622
Notes on my Talk page on the CS Wiki are also acceptable, as are e-mails to this address: dragoonwraith+nifscript[at]gmail.com
Messages or posts on any other forum or website may likely be missed for extended periods of time.
== Credits ==
- The Oblivion Script Extender team: ianpatt, behippo, and scruggsywuggsy the ferretWithout OBSE, I would have lost interest in modding Oblivion long, long ago, and without the plug-in API that they created, this project never could have happened
Special thanks to Scruggs and behippo for answering myriad questions about coding for the OBSE plug-in API, and to Scruggs for implementing new features just for me! - The NifTools NifLib team: Shon, amorilia, tazpn, xoalinThe NifTools team had done all the hard work for me - all I did was provide an interface between OBSE and NifLib. Kudos to them on an incredible piece of work.
Special thanks to amorilia for answering some questions on Nifs in general, and to tazpn for answering some NifLib specific questions. - Timeslip, author of the Oblivion Mod Manager and a C++ BSA ReaderFor his excellent BSA reading code, which he had contributed to the NifTools team. Many thanks for his tireless help in debugging the utility, and many apologies for wasting his time with such a silly mistake! Also thanks for OBMM, which I'm using to distribute this mod.
- Jean-Loup Gailly and Mark AdlerThe zlib code allows me to read BSA files that I otherwise would not be able to read. zlib is an excellent free utility, one of the best products of open source design to date.
- SpeedoHelp with statically linking zlib into NifScript.
- throttlekitty, JDFan, and trollfFor answering questions that I had about Nifs on the CS Forum.
- opajFor help testing and for working on a better version of the demonstration plugin.
- HeX_0ffFor creating Unnecessary Violence, an incredible mod using NifScript, and for general help and feedback on NifScript.
Warning
This utility creates new files. These do take space on your hard drive.
Included is a Windows Batch file which will delete Nif's altered by NifScript from your hard drive. To use it, simply double-click on the file, and it will remove the files. It does so blindly, it does not know whether or not that file is still needed. Essentially, this cannot be used except to cleanly remove NifScript from your computer. If you use this Batch file when a save game still needs one of those files, you will get missing mesh icons.
Download:
- from http://tesnexus.com/downloads/file.php?id=21292
Please post any ideas you have for the utility here!