MCPcopy Create free account
hub / github.com/OneLoneCoder/olcPixelGameEngine / PlaySample

Method PlaySample

extensions/olcPGEX_Sound.h:350–359  ·  view source on GitHub ↗

Add sample 'id' to the mixers sounds to play list

Source from the content-addressed store, hash-verified

348
349 // Add sample 'id' to the mixers sounds to play list
350 void SOUND::PlaySample(int id, bool bLoop)
351 {
352 olc::SOUND::sCurrentlyPlayingSample a;
353 a.nAudioSampleID = id;
354 a.nSamplePosition = 0;
355 a.bFinished = false;
356 a.bFlagForStop = false;
357 a.bLoop = bLoop;
358 SOUND::listActiveSamples.push_back(a);
359 }
360
361 void SOUND::StopSample(int id)
362 {

Callers

nothing calls this directly

Calls 1

push_backMethod · 0.80

Tested by

no test coverage detected