PlayIdle

From the Fallout3 GECK Wiki
Jump to navigation Jump to search
< [[::Category:Functions|Category:Functions]]

A function included in the GECK version 1.1.0.36.

Description

PlayIdle causes the calling actor to play a specified idle animation.

Syntax

[help]
[Actor].PlayIdle IdleName:EditorID


Notes

  • Calling playidle on the player directly is bugged, but you can use it on the player if the player's the implied reference of an actor effect's script, or if you pass the player to a local ref variable first and call playidle on that.
  • begin ScriptEffectUpdate
    playidle someIdle
    End
    ref someRefVar
    Begin someBlock
    let someRefVar := playerref
    someRefVar.playidle someIdle
    End
  • There is no stopidle function but you can stop a looping idle by playidling a neutral stance anim and then stop the script.
  • Playidle takes the actual editorID string of the idle as parameter, not the converted formID, so will take a string variable as parameter, not a ref variable.
  • When called on the player directly, PlayIdle will only work under very specific circumstances:
    • When the game is in "Flying Camera" mode, as triggered by ToggleFlyCam
    • During the frame in which the player activated the scripted reference, and only if the scripted reference's default activation is not triggered. For example, the following code will cause the player to play the appropriate Brahmin Push when they activate the scripted reference:
    Begin OnActivate player
    	if IsPC1stPerson
    		player.PlayIdle Loose1stPBrahminPush
    	else
    		player.Playidle Loose3rdPBrahminPush
    	endif
    End
  • The above limitations can be overcome by placing the animation outside of the characters folder. This requires usage of 3rd party tools, such as FO3Edit, and is demonstrated here. When using vanilla animations in this manner, their file names must be changed, even if they are placed in a new folder. Note that adding a prefix to the file name works, but adding a suffix does not.

See Also