Difference between revisions of "NiObjectNETAddExtraData"
imported>DragoonWraith m (NifAddExtraData moved to NiObjectNETAddExtraData: new name for function as of alpha 5.) |
imported>DragoonWraith |
||
| Line 2: | Line 2: | ||
'''Syntax''' |
'''Syntax''' |
||
(short:ExtraDataID) |
(short:ExtraDataID) NiObjectNETAddExtraData string:Name string:Type short:NifID ''short:blockID'' |
||
Adds an ExtraData node of the appropriate type with the appropriate name to the specified nif. Returns the index of the newly-added ExtraData. |
Adds an ExtraData node of the appropriate type with the appropriate name to the specified block of the nif. Like all NifSE functions, <tt>blockID</tt> defaults to 0, the root node, if not given. Returns the index of the newly-added ExtraData. |
||
{{NifSE ExtraData Type List}} |
{{NifSE ExtraData Type List}} |
||
== See Also == |
== See Also == |
||
* [[NiObjectNETGetNumExtraData]] |
|||
* [[NifGetNumExtraData]] |
|||
* [[NiObjectNETDeleteExtraData]] |
|||
* [[NifDeleteNthExtraData]] |
|||
[[Category:NifSE| |
[[Category:NifSE|NiObjectNETAddExtraData]] |
||
[[Category:NifSE (ExtraData)|AddExtraData]] |
|||
Revision as of 09:32, 27 August 2010
This is a command from NifSE.
Syntax
(short:ExtraDataID) NiObjectNETAddExtraData string:Name string:Type short:NifID short:blockID
Adds an ExtraData node of the appropriate type with the appropriate name to the specified block of the nif. Like all NifSE functions, blockID defaults to 0, the root node, if not given. Returns the index of the newly-added ExtraData.
ExtraData Types
These are all of the NIF block types that derive from NiExtraData. NiExtraData blocks are included in a NIF via the ExtraData list of NiObjectNET blocks.
- NiObject (ancestor)
- NiExtraData *
- BSBound
- BSFurnitureMarker†
- NiBinaryExtraData A
- NiBinaryVoxelData A
- NiBooleanExtraData N
- NiColorExtraData A
- NiFloatExtraData N
- NiFloatsExtraData A
- NiIntegerExtraData N
- BSXFlags N
- NiIntegersExtraData A
- NiStringExtraData S
- NiStringsExtraData A
- NiTextKeyExtraData
- NiVectorExtraData A
- NiVertWeightsExtraData A
- NiExtraData *
* NiExtraData is effectively an abstract type - it does not do anything on its own. Use any of the subsequent sub-children to indicate the type of Extra Data that is desired.
† BSFurnitureMarkers have their own, separate functions, BSFurnitureMarkerGetPositionRefs and BSFurnitureMarkerSetPositionRefs.
A These data types are arrays, and thus their values can be gotten with NiExtraDataGetArray and set with NiExtraDataSetArray.
N These data types are numbers, and thus their values can be gotten with NiExtraDataGetNumber and set with NiExtraDataSetNumber.
S These data types are strings, and thus their values can be gotten with NiExtraDataGetString and set with NiExtraDataSetString.
All other types are not supported by NifSE v1.0. They may be added to or deleted from NiObjectNET blocks, but not read or edited in any way.