AttachLine

From GECK
Jump to: navigation, search


A function added by the JIP NVSE Plugin.

Description

Attaches a line mesh to a selected node in the loaded 3D model of the calling reference.

The function takes 7 arguments, as follows:

  • targetNode - The name of the parent node where the line is attached as a child.
  • lineName - The name that is given to the line block (this name can later be used to transform/remove the line using any of the NifBlock functions).
  • length - The initial length of the line, in game units (the length can later be changed using SetNifBlockScale; length = scale).
  • red, green, blue & alpha - The RGB colour and alpha (opacity) of the line; each 0-255.

Syntax

[help]
(successful:0/1) reference.AttachLine targetNode:string lineName:string length:float red:int{0-255} green:int{0-255} blue:int{0-255} alpha:int{0-255}

Example

player.AttachLine "ProjectileNode" "LaserPointer" 384 255 95 95 179 

Notes

  • On successful attach, the function returns 1, otherwise 0.
  • To remove an attached line completely, use RemoveNifBlock.

See Also