+inline void AddAnimatorMessage(EventThreadServices& eventThreadServices, const Animation& animation, AnimatorBase& animator)
+{
+ using LocalType = MessageValue1<Animation, OwnerPointer<AnimatorBase> >;
+
+ // Reserve some memory inside the message queue
+ uint32_t* slot = eventThreadServices.ReserveMessageSlot(sizeof(LocalType));
+
+ // Construct message in the message queue memory; note that delete should not be called on the return value
+ OwnerPointer<AnimatorBase> parameter(&animator);
+ new(slot) LocalType(&animation, &Animation::AddAnimator, parameter);
+}
+
+inline void PlayAfterMessage(EventThreadServices& eventThreadServices, const Animation& animation, float delaySeconds)
+{
+ using LocalType = MessageValue1<Animation, float>;
+
+ // Reserve some memory inside the message queue
+ uint32_t* slot = eventThreadServices.ReserveMessageSlot(sizeof(LocalType));
+
+ // Construct message in the message queue memory; note that delete should not be called on the return value
+ new(slot) LocalType(&animation, &Animation::PlayAfter, delaySeconds);
+}
+
+inline void SetLoopingModeMessage(EventThreadServices& eventThreadServices, const Animation& animation, bool loopingMode)
+{
+ using LocalType = MessageValue1<Animation, bool>;
+
+ // Reserve some memory inside the message queue
+ uint32_t* slot = eventThreadServices.ReserveMessageSlot(sizeof(LocalType));
+
+ // Construct message in the message queue memory; note that delete should not be called on the return value
+ new(slot) LocalType(&animation, &Animation::SetLoopingMode, loopingMode);
+}