EnableAI - Actor
Member of: Actor Script
Enables or disables this actor's AI.
SyntaxEdit
Function EnableAI(bool abEnable = true, bool abPauseVoice = false) native
ParametersEdit
- abEnable: Whether to enable or disable the AI.
- Default: True
- abPauseVoice: Ignored if abEnable is True. If abEnable is False, setting this to True will pause the Actor's current voice audio, so it can be resumed upon re-enable. If left False, existing voice audio will play to completion.
- Default: False
Return ValueEdit
None.
ExamplesEdit
; Turn off evil AI
EvilActor.EnableAI(false)
; Turn on good guy's AI
GoodActor.EnableAI()
; Freeze frame!
JGeils.EnableAI(false, true)
Utility.Wait(5)
; Now go!
JGeils.EnableAI()