Mod:Creation Kit/SetHasCharGenSkeleton - Actor

Member of: Mod:Creation Kit/Actor Script

Flags this actor as having a fully char gen editable skeleton or not.

Syntax
Function SetHasCharGenSkeleton(bool abCharGen = true) native

Parameters

 * abCharGen: True to set actor for full char gen editing, false to restore them to normal.
 * Default: True

Return Value
None.

Examples
PlayerSpouse.SetHasCharGenSkeleton(true)
 * Set player spouse up for editing in char gen menu

Example: When is the CharGenSkeleton reset done?
Function SomeFunction ;register for this event before adding/removing the CharGenSkeleton. We want to know when it unregisters, which means ;the CharGenSkeleton has finished deleting the graph RegisterForAnimationEvent(Game.GetPlayer, "FirstPersonInitialized")

;now add or remove the CharGenSkeleton. In this example, we're removing it PlayerREF.SetHasCharGenSkeleton(False) EndFunction

Event OnAnimationEventUnregistered(ObjectReference akSource, string asEventName) If asEventName == "FirstPersonInitialized" ;now register for the event that fires when the third person graph is fully available RegisterForAnimationEvent(Game.GetPlayer, "initiateStart") EndIf EndEvent
 * we registered for the FirstPersonIntitialized event, but what we really want to know is when it unregisters

Event OnAnimationEvent(ObjectReference akSource, string asEventName) ;CharGenSkeleton has finished being removed or added, third person animations are now available If (asEventName == "initiateStart") ;whatever scripting you want when the graph is available, such as enabling third person controls EndIf EndEvent