GetName - Form

Revision as of 07:36, 27 February 2015 by imported>Terra Nova2 (→‎Notes: typo)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

SKSE Member of: Form Script

Returns the name of the passed form. (This function requires SKSE)

SyntaxEdit

String Function GetName() native

ParametersEdit

  • None.

Return ValueEdit

  • The name of the form as a string.

ExamplesEdit

; Obtain Bob's name and show a message using it.
String BobName = Bob.GetBaseObject().GetName()
Debug.MessageBox("My name's " + BobName + "!")
; My name's Bob!


; Remove all the NPC's items if his name's Bob
if BobReference.GetBaseObject().GetName() == "Bob"
  BobReference.RemoveAllItems()
endif

NotesEdit

  • This function does not work on actors or object references, use the actor base or base object instead.
  • This doesn't return the name in its EditorID form. But name under the name column. If using this function, take in account for forms that may not have a name.

See AlsoEdit