<앞으로 자주 찾아봐야할 홈페이지>
스파인 api 사이트
http://ko.esotericsoftware.com/spine-api-reference#AnimationState-setAnimation
찾기 기능 이용해서 api 명세 확인, 번역기라도 돌려서…
이런식으로
addAnimation ( | int trackIndex, string animationName, bool loop, float delay): TrackEntry |
Queues an animation by name.
See addAnimation.
addAnimation ( | int trackIndex, Animation animation, bool loop, float delay): TrackEntry |
Adds an animation to be played after the current or last queued animation for a track. If the track is empty, it is equivalent to calling setAnimation.
- delay If > 0, sets delay. If <= 0, the delay set is the duration of the previous track entry minus any mix duration (from the AnimationStateData) plus the specified delay (ie the mix ends at (delay = 0) or before (delay < 0) the previous track entry duration). If the previous entry is looping, its next loop completion is used instead of its duration.
- <return> A track entry to allow further customization of animation playback. References to the track entry must not be kept after the dispose event occurs.
addEmptyAnimation ( | int trackIndex, float mixDuration, float delay): TrackEntry |
Adds an empty animation to be played after the current or last queued animation for a track, and sets the track entry's mixDuration. If the track is empty, it is equivalent to calling setEmptyAnimation.
See setEmptyAnimation.
- delay If > 0, sets delay. If <= 0, the delay set is the duration of the previous track entry minus any mix duration plus the specified delay (ie the mix ends at (delay = 0) or before (delay < 0) the previous track entry duration). If the previous entry is looping, its next loop completion is used instead of its duration.
- <return> A track entry to allow further customization of animation playback. References to the track entry must not be kept after the dispose event occurs.
addListener ( | AnimationStateListener listener): void |
Adds a listener to receive events for all track entries.
apply ( | Skeleton skeleton): bool |
Poses the skeleton using the track entry animations. The animation state is not changed, so can be applied to multiple skeletons to pose them identically.
- <return> True if any animations were applied.
clearListenerNotifications ( | ): void |
Discards all listener notifications that have not yet been delivered. This can be useful to call from an AnimationStateListener when it is known that further notifications that may have been already queued for delivery are not wanted because new animations are being set.
clearListeners ( | ): void |
Removes all listeners added with addListener.
clearNext ( | TrackEntry entry): void |
Removes the next and all entries after it for the specified entry.
clearTrack ( | int trackIndex): void |
Removes all animations from the track, leaving skeletons in their current pose.
It may be desired to use setEmptyAnimation to mix the skeletons back to the setup pose, rather than leaving them in their current pose.
clearTracks ( | ): void |
Removes all animations from all tracks, leaving skeletons in their current pose.
It may be desired to use setEmptyAnimations to mix the skeletons back to the setup pose, rather than leaving them in their current pose.
getCurrent ( | int trackIndex): TrackEntry |
Returns the track entry for the animation currently playing on the track, or null if no animation is currently playing.
- <return> May be null.
removeListener ( | AnimationStateListener listener): void |
Removes the listener added with addListener.
setAnimation ( | int trackIndex, string animationName, bool loop): TrackEntry |
Sets an animation by name.
See setAnimation.
setAnimation ( | int trackIndex, Animation animation, bool loop): TrackEntry |
Sets the current animation for a track, discarding any queued animations. If the formerly current track entry was never applied to a skeleton, it is replaced (not mixed from).
- loop If true, the animation will repeat. If false it will not, instead its last frame is applied if played beyond its duration. In either case trackEnd determines when the track is cleared.
- <return> A track entry to allow further customization of animation playback. References to the track entry must not be kept after the dispose event occurs.
https://pixijs.download/dev/docs/index.html
pixijs api 사이트도 앞으로 자주 찾아보게 될 것.
'그래픽스 > WebGl' 카테고리의 다른 글
[2D WebGL][pixiJS] Renderer, Ticker, & Stage (0) | 2022.05.13 |
---|---|
[2D WebGL][pixi.Js] 세부사항 (0) | 2022.05.10 |
[2D WebGL][pixiJS] Getting Started! (0) | 2022.05.09 |
[2D WebGL][pixiJS] Architecture Overview (0) | 2022.05.09 |
[3D WebGL][three.js] three.js 프로젝트 시작해보기 (0) | 2022.05.09 |