Description
The LocalTransform
property of the SoundHandle
class represents the local transformation of the sound relative to its parent. This property is particularly useful when the sound is set to follow a parent object, allowing you to define the sound's position and orientation in relation to that parent.
Usage
Use the LocalTransform
property to set or get the local transformation of a sound when it is following a parent. This can be used to adjust the sound's position and rotation relative to its parent object.
Example
// Assuming 'soundHandle' is an instance of SoundHandle
// Set the local transform of the sound
soundHandle.LocalTransform = new Transform(Vector3.Zero, Rotation.Identity);
// Get the current local transform of the sound
Transform currentLocalTransform = soundHandle.LocalTransform;