GS_MotionComposite

Runtime deep-copy motion instance with proxy entity overrides — created from GS_MotionAsset for per-entity playback.

GS_MotionComposite is the runtime instance of a motion, created from a GS_MotionAsset. It deep-copies all tracks so each entity gets independent playback state, and applies proxy overrides to redirect specific tracks to different entities in the hierarchy.

For usage guides and setup examples, see The Basics: GS_Core.


GS_MotionComposite extends GS_Motion. When an asset’s CreateRuntimeComposite() is called, all tracks are SC-cloned (serialization-context cloned) into a new composite instance. This ensures each entity playing the same motion has its own independent track state — no shared mutation.


API Reference

MethodParametersReturnsDescription
ApplyProxiesAZ::EntityId owner, vector<GS_MotionProxy> proxiesvoidMatches proxy trackIds to tracks and overrides the target entity for each matched track.

How It Works

  1. Creation: GS_MotionAsset::CreateRuntimeComposite() deep-copies all asset tracks into a new composite.
  2. Proxy Application: ApplyProxies() walks the proxy list, matching each proxy’s m_trackId to a track’s m_id. Matched tracks redirect their owner entity to the proxy’s m_proxyEntity.
  3. Playback: The composite plays exactly like a regular GS_Motion — it ticks tracks, applies easing, and calls Update().
  4. Cleanup: On Unload(), the composite cleans up all deep-copied tracks.

See Also


Get GS_Core

GS_Core — Explore this gem on the product page and add it to your project.