Animator Lua API

From Off Grid Wiki
Revision as of 11:13, 9 May 2017 by Harry (talk | contribs) (Create Animator documentation)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

Animator

Description

Allows the user to set properties of a mission objects Unity animator The animator allows users to set key keyframe-able animations to control a large amount of components. See [Unity's documentation] for more details

Functions

SetBool

Animator.SetBool(missionObjectName, parameterName, value)

Expected parameter types

missionObjectName string
parameterName string
value bool

Description: Sets a bool parameter by name

Returns: Nothing

SetFloat

Animator.SetFloat(missionObjectName, parameterName, value)

Expected parameter types

missionObjectName string
parameterName string
value number

Description: Sets a float parameter by name

Returns: Nothing

SetInt

Animator.SetInt(missionObjectName, parameterName, value)

Expected parameter types

missionObjectName string
parameterName string
value number

Description: Sets a int parameter by name

Returns: Nothing

SetTrigger

Animator.SetTrigger(missionObjectName, parameterName)

Expected parameter types

missionObjectName string
parameterName string

Description: Begins a trigger parameter by name

Returns: Nothing

GetBool

Animator.GetBool(missionObjectName, parameterName)

Expected parameter types

missionObjectName string
parameterName string

Description: Gets the current value of a bool parameter by name

Returns: The current bool value of the parameter

GetFloat

Animator.GetFloat(missionObjectName, parameterName)

Expected parameter types

missionObjectName string
parameterName string

Description: Gets the current value of a float parameter by name

Returns: The current float value of the parameter

GetInt

Animator.GetInt(missionObjectName, parameterName)

Expected parameter types

missionObjectName string
parameterName string

Description: Gets the current value of a int parameter by name

Returns: The current int value of the parameter


Docs last hacked together on: 09/05/2017 12:04