aboutsummaryrefslogtreecommitdiff
path: root/src/crepe/api/AudioSource.cpp
blob: c646aebe22a0ac991e56817fd04db2896efea826 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#include "AudioSource.h"

using namespace crepe;
using namespace std;

AudioSource::AudioSource(game_object_id_t id, const Asset & src) :
	Component(id),
	source(src)
{ }

void AudioSource::play(bool looping) {
	this->loop = looping;
	this->playing = true;
}

void AudioSource::stop() {
	this->playing = false;
}