ProtoFlux:Play One Shot And Wait

From Resonite Wiki
Revision as of 22:18, 19 February 2024 by 989onan (talk | contribs) (add more info)
Play One Shot And Wait
*
OnStartedPlaying
Clip
OnFinishedPlaying
Volume
Audio
Speed
Spatialize
SpatialBlend
Point
Root
ParentUnderRoot
Priority
Doppler
MinDistance
MaxDistance
Rolloff
DistanceSpace
MinScale
MaxScale
Group
LocalOnly
Audio

Play One Shot is a ProtoFlux node that creates a new audio source under the provided Root (Slot) (except when ParentUnderRoot (bool) is enabled) with the provided parameters. It will then wait and fire OnFinishedPlaying (Continuation) when the audio reaches the end.

Inputs

* (AsyncCall)

Play the audio clip with the provided parameters

Clip (IAssetProvider`1<AudioClip>)

The audio clip to play on the newly created sound object

Volume (float)

The volume to play the audio at.

Speed (float)

The speed to play the audio at.

Spatialize (bool)

Whether the audio played will have spatialization.

SpatialBlend (float)

How spatialized the audio played will be.

Point (float3)

The point to play the audio if Root (Slot) is not provided.

Root (Slot)

The slot to play the audio under. The audio will not be audible if the slot is part of a disabled hierarchy.

ParentUnderRoot (bool)

Whether to put the audio under the root of the world or not.

Priority (int)

How much priority this audio clip has, which can override others when the buffer is too full. So this audio has more priority to be played in such cases.

Doppler (bool)

Whether the audio clip played should have Doppler. What is Doppler?

MinDistance (float)

The distance the audio stops becoming louder when getting closer to the source.

MaxDistance (float)

The max distance the audio can be heard from until it is inaudible

Rolloff (AudioRolloffMode)

The AudioRolloffMode the audio created should use.

DistanceSpace (AudioDistanceSpace)

The AudioDistanceSpace the audio created should use.

MinScale (float)

This article or section is a Stub. You can help the Resonite Wiki by expanding it.


MaxScale (float)

This article or section is a Stub. You can help the Resonite Wiki by expanding it.


Group (AudioTypeGroup)

What AudioTypeGroup this node is in.

LocalOnly (bool)

Whether this audio should only play locally for the user that fired the node.

Outputs

OnStartedPlaying (AsyncCall)

When the audio clip has successfully started playing

OnFinishedPlaying (Continuation)

The the audio clip has finished playing

Audio (AudioOutput)

The Audio Output component created to play the audio. The Get Slot node can be used to get the created slot for the one shot. This will only have a value during the OnStartedPlaying (AsyncCall) impulse.

Examples