Skip to content

Flash

Utilities to make interacting with the Flash api easier.

Calls a game function, whether this be an interop function or an internal function. If “fn” is a string, it will be treated as an actionscript path.

ParameterTypeDescription
fnstring | FunctionThe function to call.
argsany[]The arguments to pass to the function.

Returns: T

Gets an actionscript object at the given location.

ParameterTypeOptionalDefaultDescription
pathstringThe path of the object, relative to Game.
parsebooleanfalseWhether to call JSON.parse on the return value.

Returns: T | null

Gets an actionscript object at the given location.

ParameterTypeOptionalDefaultDescription
pathstringThe path of the object, relative to Game.
parsebooleanfalseWhether to call JSON.parse on the return value.
defaultValuenullnull

Returns: T | null

Determines whether an actionscript path is null.

ParameterTypeDescription
pathstringThe path of the game object.

Returns: boolean

Sets an actionscript object at the given location.

ParameterTypeDescription
pathstringThe path of the object, relative to Game.
valueanyThe value to set.

Returns: void