Background for Skyrim SE
Member of the Form script
intfunctionGetFormID()Native

Description

Wiki Description

Returns this form's form ID.

Documentation Comment

Returns the formID for this object


Caveats

CK Wiki - Notes

  • The value returned by GetFormID is always in decimal. This can be confusing to anyone expecting the return value to be the hex value for a form found in the Creation Kit. You will have to convert the value yourself. This can be easily done with the windows calculator, by selecting "View → Programmer" and selecting "Dec", pasting the value in, and then selecting "hex".

Example:

Int myFormID = SomeTree.GetFormID()
;result...
768339 = BB953; or 000BB953 in the editor.

Examples

; Obtains the form id of the main quest
int formID = mainQuest.GetFormID()

Auto-Generated Example

int returnedValue = myForm__toCallFunctionOn.GetFormID()

Related Pages


Additional References

View this function’s page on the Skyrim Creation Kit Wiki

Some data provided by the Skyrim Creation Kit Wiki. Licensed under the Creative Commons Attribution-ShareAlike license.