I have a large backlog of new Castle Game Engine improvements to announce 🙂 Let me try to make it up, by making a new announcement more-or-less daily for the following week. Remember that everything I describe is available to you right now: simply use the Castle Game Engine version from GitHub (6.5).
-
We start with the improvements to our PlayAnimation method. It is the primary way to run animations using Castle Game Engine (documented in the manual).
- New overloaded
PlayAnimation
version with TPlayAnimationParameters, that allows to specify:- StopNotification: Easy and reliable way to watch when animation stopped.
- TransitionDuration: Animation blending (see my earlier post).
- InitialTime: Start animation from the middle.
- Forward: Play animation forward or backward.
- It also, of course, allow to specify basics: animation Name and whether it loops.
- It is the only way how we animate stuff in our new game “The Unholy Society” (well, aside from some user-interface animations), so it’s really flexible.
-
New overloaded
PlayAnimation(AnimationName: string, Loop: boolean)
version. This replaces (deprecates) older overload with"Looping: TPlayAnimationLooping"
parameter — the TPlayAnimationLooping did not really prove to be of much use, so it’s simpler to just specify Loop as a boolean.
- New overloaded
-
I have also written a large documentation “How to animate things using X3D”. This may be useful for developers that want to understand how the X3D nodes are used for animations. The
PlayAnimation
method, under the hood, uses the X3D nodes.
One Reply to “Engine improvements: Rejuvenated PlayAnimation method (easily play animations backward, with blending, stop notifications…)”