Difference between revisions of "NiExtraDataSetNumber"

From the Oblivion ConstructionSet Wiki
Jump to navigation Jump to search
imported>DragoonWraith
(New page: This is a command from NifSE. '''Syntax''' (number:value) NiExtraDataSetNumber short:nifID ''short:blockID'' (number:value) NiEDSetNum short:nifID ''short:blockID'' ...)
 
imported>DragoonWraith
 
Line 2: Line 2:


'''Syntax'''
'''Syntax'''
  (number:value) NiExtraDataSetNumber short:nifID ''short:blockID''
  (bool:success) NiExtraDataSetNumber number:value short:nifID ''short:blockID''
  (number:value) NiEDSetNum short:nifID ''short:blockID''
  (bool:success) NiEDSetNum number:value short:nifID ''short:blockID''


If the block indicated by <tt>blockID</tt> is of a <tt>NiExtraData</tt>-derived class with a numerical data type, sets the block's value. Because <tt>blockID</tt> defaults to 0, which is usually the NIF's root, a <tt>NiNode</tt>, <tt>blockID</tt> must almost always be specified when using this function.
If the block indicated by <tt>blockID</tt> is of a <tt>NiExtraData</tt>-derived class with a numerical data type, sets the block's value. Because <tt>blockID</tt> defaults to 0, which is usually the NIF's root, a <tt>NiNode</tt>, <tt>blockID</tt> must almost always be specified when using this function. The type of <tt>value</tt> varies according to the type of numerical <tt>NiExtraData</tt> is being set; see below.


Returns 1 if successful, 0 otherwise.
Returns 1 if successful, 0 otherwise.

Latest revision as of 10:46, 31 August 2010

This is a command from NifSE.

Syntax

(bool:success) NiExtraDataSetNumber number:value short:nifID short:blockID
(bool:success) NiEDSetNum number:value short:nifID short:blockID

If the block indicated by blockID is of a NiExtraData-derived class with a numerical data type, sets the block's value. Because blockID defaults to 0, which is usually the NIF's root, a NiNode, blockID must almost always be specified when using this function. The type of value varies according to the type of numerical NiExtraData is being set; see below.

Returns 1 if successful, 0 otherwise.

Numerical NiExtraData Types

The following NiExtraData-derived blocks have numerical data of the type indicated.

  • NiBooleanExtraData - bool
  • NiFloatExtraData - float
  • NiNiIntegerExtraData - short
    • BSXFlags - short, containing a bit field:
      Bit 0 = enable animation
      Bit 1 = enable collision
      Bit 2 = is skeleton nif?
      Bit 3 = unknown; set to 1 on Signs
      Bit 4 = FlameNodes present
      Bit 5 = EditorMarkers present

See Also[edit | edit source]