![]() |
vkmEngine 1.0.0
A C++ game engine · vkmengine.com
|
A request to hear a clip once, from gameplay that owns no entity for it. More...
#include <audio_events.h>
Static Public Member Functions | |
| static PlaySoundEvent | at (AudioClipHandle clip, const glm::vec3 &position, float volume=1.0f) |
A request to hear clip once, from position. | |
A request to hear a clip once, from gameplay that owns no entity for it.
For when no AudioSource fits: a sound on an entity about to go, or one that must overlap itself. There is no id, so it cannot be stopped or moved; loop is ignored. A request made during Simulation is heard the same frame; at the voice ceiling it is dropped.
events().emit(PlaySoundEvent::at(m_chime, transform->position));
|
inlinestatic |
A request to hear clip once, from position.
| clip | Clip to play; an invalid handle is heard as nothing. |
| position | Where it sounds from, in world space. |
| volume | Linear gain, multiplied into the master. |