Skip to content

format

typescript
Animation.IsPlaying(name)

class: Animation

description

Check if the animation with the given name is currently playing.

parameter

param_nametypedescription
namestringThe name of the animation clip.

reture

typedescription
booleanTrue if the animation is playing, false otherwise.

code example

typescript
let obj = new GameObject();
let animation = obj.AddComponent<Animation>(Animation);
animation.IsPlaying("clip_name");