Merge branch 'master' of github.com:sippeangelo/Escape-the-Dawn
Conflicts: Escape-the-Dawn/Systems/SoundsSystem.cpp
This commit is contained in:
@@ -1,24 +1,25 @@
|
||||
#ifndef SoundEmitter_h__
|
||||
#define SoundEmitter_h__
|
||||
|
||||
#include "AL/al.h"
|
||||
#include "AL/alc.h"
|
||||
|
||||
#include "System.h"
|
||||
#include "Components/SoundEmitter.h"
|
||||
#include <AL/al.h>
|
||||
#include <AL/alc.h>
|
||||
#include <windows.h>
|
||||
|
||||
namespace System
|
||||
namespace Systems
|
||||
{
|
||||
|
||||
class SoundSystem : public System
|
||||
{
|
||||
public:
|
||||
SoundSystem(World* world) : System(world)
|
||||
{
|
||||
SoundSystem(World* world);
|
||||
|
||||
}
|
||||
void Update(double dt) override;
|
||||
void Update(double dt, EntityID entity, EntityID parent) override;
|
||||
void UpdateEntity(double dt, EntityID entity, EntityID parent) override;
|
||||
void OnComponentCreated(std::string type, std::shared_ptr<Component> component) override;
|
||||
void PlaySound(std::shared_ptr<Components::SoundEmitter> emitter, std::string fileName);
|
||||
void LoadFile(const char* fileName);
|
||||
|
||||
@@ -3,7 +3,8 @@
|
||||
//#include <fstream>
|
||||
|
||||
|
||||
System::SoundSystem::SoundSystem(World* world)
|
||||
Systems::SoundSystem::SoundSystem(World* world)
|
||||
: System(world)
|
||||
{
|
||||
|
||||
//initialize OpenAL
|
||||
@@ -18,12 +19,12 @@ System::SoundSystem::SoundSystem(World* world)
|
||||
|
||||
}
|
||||
|
||||
void System::SoundSystem::Update(double dt)
|
||||
void Systems::SoundSystem::Update(double dt)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
void System::SoundSystem::Update(double dt, EntityID entity, EntityID parent)
|
||||
void Systems::SoundSystem::UpdateEntity(double dt, EntityID entity, EntityID parent)
|
||||
{
|
||||
auto soundEmitter = m_World->GetComponent<Components::SoundEmitter>(entity, "SoundEmitter");
|
||||
if(soundEmitter == nullptr)
|
||||
@@ -32,7 +33,7 @@ void System::SoundSystem::Update(double dt, EntityID entity, EntityID parent)
|
||||
|
||||
}
|
||||
|
||||
void System::SoundSystem::PlaySound(std::shared_ptr<Components::SoundEmitter> emitter, std::string fileName)
|
||||
void Systems::SoundSystem::PlaySound(std::shared_ptr<Components::SoundEmitter> emitter, std::string fileName)
|
||||
{
|
||||
//LoadFile(fileName);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user